A lexical (my) variable get cleared when exiting the tightest lexical scope (curlies or file) in which it is found.
sub f { my $x = ...; { my $y = ...; ... # $y cleared here. } ... # $x cleared here. }
It doesn't matter how the scope is exited. It'll get cleared on return, die, next, etc.
You obviously didn't read the documentation for $|.
In reply to Re: my $var
by ikegami
in thread my $var
by toniax
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |