Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Invoking a method whose name is computed

by tobyink (Abbot)
on Oct 01, 2012 at 23:43 UTC ( #996768=note: print w/ replies, xml ) Need Help??


in reply to Invoking a method whose name is computed

Not really.

You could potentially use Object::Tap...

use 5.010; use Object::Tap -package => 'UNIVERSAL'; sub Foo::bar { say "Foo::bar"; } Foo->tap(join 'a', 'b', 'r');
perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'


Comment on Re: Invoking a method whose name is computed
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (14)
As of 2015-07-30 13:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (271 votes), past polls