On Fri, May 07, 2004 at 09:05:18PM +0200, Lukas Mai wrote: > # Some names are evil choices. > -my %keywords = map +($_, 1), qw{ BEGIN INIT CHECK END DESTROY AUTOLOAD }; > +my %keywords = map +($_, 1), qw{ BEGIN INIT CHECK END DESTROY AUTOLOAD import }; This part I understand. > +# Load Carp::croak on demand. And I understand why you'd want to do that. > +sub _croak { > + require Carp; > + no warnings 'redefine'; > + *_croak = \&Carp::croak; > + goto &Carp::croak; > +} This is a little overdoing it. You're optimizing the case where the program has died but someone happens to have caught it in an eval. Just do: sub _croak { require Carp; goto &Carp::croak; } -- Michael G Schwern schwern@pobox.com http://www.pobox.com/~schwern/ Beer still cheaper than crack!Thread Previous | Thread Next