Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Let a module call a sub of the caller

by tobyink (Abbot)
on Sep 07, 2012 at 12:38 UTC ( #992303=note: print w/ replies, xml ) Need Help??


in reply to Let a module call a sub of the caller

B::Hooks::EndOfScope or perhaps Hook::AfterRuntime (or even a combination of the two) ought to do the trick.

perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'


Comment on Re: Let a module call a sub of the caller

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (9)
As of 2014-08-28 05:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (257 votes), past polls