Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^2: AUTOLOAD not following @ISA as expected

by chibiryuu (Beadle)
on Aug 02, 2005 at 21:16 UTC ( [id://480299]=note: print w/replies, xml ) Need Help??


in reply to Re: AUTOLOAD not following @ISA as expected
in thread AUTOLOAD not following @ISA as expected [solved]

Yes, that is what I mean.
  • Comment on Re^2: AUTOLOAD not following @ISA as expected

Replies are listed 'Best First'.
Re^3: AUTOLOAD not following @ISA as expected
by dave_the_m (Monsignor) on Aug 02, 2005 at 22:17 UTC
    Yes, that is what I mean
    In that case I think you want to replace sub {goto \&{$#_ ? $set : $get}}; with
    sub { my $self = shift; @_ ? $self->$set(@_) : $self->$get(@_) };
    or
    sub { goto &{$_[0]->can($#_ ? $set : $get)} };

    Dave.

Re^3: AUTOLOAD not following @ISA as expected
by jhourcle (Prior) on Aug 02, 2005 at 21:47 UTC

    AUTOLOAD doesn't play nicely with inheritance -- it takes control of everything. (including DESTROY, which can make for some interesting problems).

    You may want to take a look at NEXT

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://480299]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (2)
As of 2024-04-24 23:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found