Where do you get this definition of "special" from, they are listed under perlvar#SPECIAL-VARIABLES.
The docs specify the terminology
> $/ and $\ are special: They are magical vars. ... $1 is special: It's a magical var
OK, so your point seems to be that "magical vars", i.e. variables with a MAGIC attribute fail to work as expected as loop variables.
So you agree that at least those vars should raise a warning in this case?
Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
In reply to Re^7: foreach $1
by LanX
in thread foreach $1
by choroba
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |