Hi all, in perlrun under the documentation for the -a switch it states:
-a implicitly sets -n.
My testing seems to show this is not the case:
$ cat test.dat foo bar baz quux $ perl -wMstrict -M5.010 -ane 'say $F[0]' test.dat foo baz $ perl -wMstrict -M5.010 -ae 'say $F[0]' test.dat Variable "@F" is not imported at -e line 1. Global symbol "@F" requires explicit package name at -e line 1. Execution of -e aborted due to compilation errors.
Am I missing something?
In reply to perlrun: -a implicitly sets -n by 1nickt
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |