develooper Front page | perl.perl5.porters | Postings from March 2006

Why does Fatal have an AUTOLOAD?

Thread Next
From:
Joshua ben Jore
Date:
March 24, 2006 08:56
Subject:
Why does Fatal have an AUTOLOAD?
Message ID:
dc5c751d0603240856g44860136v12d88ff7df45317e@mail.gmail.com
Why does Fatal have an AUTOLOAD and when does it ever get called? I
rarely use this feature so maybe I'm just missing how it's involved.
It looks like dead code to me.

sub AUTOLOAD {
    my $cmd = $AUTOLOAD;
    $cmd =~ s/.*:://;
    &_make_fatal($cmd, (caller)[0]);
    goto &$AUTOLOAD;
}

Josh

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About