Note that this will cause a memory leak; it's a high-tech variant of $a = \$a.my $coderef = do { my $selfref; $selfref = sub { # use $selfref here for recursion }; };
Dave.
In reply to Re: sub getting reference to itself : generic way
by dave_the_m
in thread sub getting reference to itself : generic way
by calin
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |