in reply to Re: Is it possible to create a sub exclusive to a sub?
in thread Is it possible to create a sub exclusive to a sub?
That's just obfuscated syntax for
sub test { $::test{localsub} = sub { print 'localsub1'; return 12345; } unless exists $::test{localsub}; $::test{localsub}->(); }
and implies all the usual ramifications of global variable use.
Makeshifts last the longest.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Is it possible to create a sub exclusive to a sub?
by ihb (Deacon) on Sep 19, 2004 at 10:40 UTC | |
by Aristotle (Chancellor) on Sep 19, 2004 at 10:44 UTC | |
by BrowserUk (Patriarch) on Sep 19, 2004 at 11:01 UTC | |
by Aristotle (Chancellor) on Sep 19, 2004 at 11:11 UTC | |
by Aristotle (Chancellor) on Sep 19, 2004 at 11:10 UTC | |
by BrowserUk (Patriarch) on Sep 19, 2004 at 11:23 UTC | |
| |
Re^3: Is it possible to create a sub exclusive to a sub?
by BrowserUk (Patriarch) on Sep 19, 2004 at 10:28 UTC | |
by Aristotle (Chancellor) on Sep 19, 2004 at 10:35 UTC |