$_ is not block scoped; it's just an ordinary global variable that happens to be the default target for various operations.Thank you for this clear statement. I have been trapped by the globalness of $_ myself some times - it just feels quite natural for the beginner to assume that implicit assignment to $_ should also scope $_ implicitly to the assigning block.
In reply to Re^2: global $_ behavior
by jonix
in thread global $_ behavior
by verdemar
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |