Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: function availablity checking inside package

by leslie (Pilgrim)
on Apr 06, 2009 at 11:01 UTC ( [id://755685]=note: print w/replies, xml ) Need Help??


in reply to function availablity checking inside package

Hi friend,

According to your script, First perl checks the hai() in parent package(C). If it is not available then it will check the package Bn. If it is not available there also then it will check package A. If that hai() is not available in package A then it will check the UNIVERSAL package.

If that function is not available in Universal package then control comes to package C(parent packege). Here it will check the Autoload(), If it is not available then it will check the Autoload() in the following order as package Bn, package A , Universal. That's why your script prints "Calling from Universal".

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2024-03-28 14:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found