Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Which module contains an imported subroutine

by john.deighan (Novice)
on Mar 26, 2013 at 20:32 UTC ( #1025581=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub SourcePackage { my($funcname, $package) = @_;
    
    ...
    { no strict 'refs'; $coderef = \&{"$package\:\:$funcname"}; }
    return B::svref_2object($coderef)->GV->STASH->NAME;
    } # SourcePackage()
    
  2. or download this
    my $srcPkg = SourcePackage($funcname, __PACKAGE__);
    
  3. or download this
    my $srcPkg = SourcePackage($funcname);
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (3)
As of 2014-08-31 05:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (294 votes), past polls