Part of the run-time action of 'my' is to make a note to free the lexical at scope exit. The goto causes additional notes to be pushed on the savestack without any scope being exited. When the scope is finally exited, all the notes are popped off the savestack and processed.while (1) { $i = 0; again: my $x; goto again if $i++ < 100_000_000; }
Dave.
In reply to Re: "goto" memory leak
by dave_the_m
in thread "goto" memory leak
by jethro
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |