AUTOLOAD is called only after the entire inheritance tree has been checked for the method. first the tree is searched in "left-most parent wins" order for the method. then the tree is searched for an AUTOLOAD in the same order.
so if you have:
package A; ... sub AUTOLOAD { } package B; @ISA = qw(A); ... package main; my $object = new B(); $object->method();
it will look at B for method(), then it will look at A for method(), then it will look for an AUTOLOAD in B, then finally it will look for an AUTOLOAD in A.
In reply to Re: oop - obvious AUTOLOAD question
by thraxil
in thread oop - obvious AUTOLOAD question
by princepawn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |