in reply to Re^3: ARGV Problem
in thread ARGV Problem
Actually, perl does always parse the #! line, for two reasons:
The relevant quote from the perlrun manpage:
The #! line is always examined for switches as the line is being parsed. Thus, if you’re on a machine that allows only one argument with the #! line, or worse, doesn’t even recognize the #! line, you still can get consistent switch behavior regardless of how Perl was invoked, even if -x was used to find the beginning of the program.
(but it's certainly an ugly hack that it does this. After all, the idea of the shebang was that the interpreters so invoked wouldn't even be aware of its existence.)
|
|---|