in reply to how to get alias name of anonymous sub?
$\="\n"; $,="\t"; $s=sub{ print "me",(caller(0))[3]; print "mum",(caller(1))[3]; *__ANON__="__ANON__"; # reset }; sub aa { *__ANON__="aa"; goto &$s; } sub level1 { aa(); } level1(); print "not reseted ", *__ANON__; # why?
unfortunately I wasn't able to reset to default-name.
me main::aa mum main::level1 not resettet *main::aa
UPDATE:
argh of course it should be:
*aa="__ANON__"; # reset
but well this is no practical solution...
Cheers Rolf
|
|---|