|
Authored by: ThrPilgrim on Wednesday, May 23 2012 @ 11:56 AM EDT |
Can't remember when Perl got methods. But in order to resolve something like.
$object->method(@LIST)
Perl has to stat looking for method in $object's symbol table and if it can't
find it Perl then has to look up the object tree until it dose find method in
any of $object's parent classes.
This searching is expensive and can only be done at run time as the object
hierarchy may well not be known when the file with the method call is compiled.
Because of the cost of this search. Perl internally cashes the result so that it
does not have to do the search again the next time the method is called but can
jump directly to the correct subroutine in the correct package.
---
Beware of him who would deny you access to information for in his heart he
considers himself your master.[ Reply to This | Parent | # ]
|
|
|
|
|