summaryrefslogtreecommitdiff
path: root/pod/perlrun.pod
diff options
context:
space:
mode:
authorGisle Aas <gisle@activestate.com>2006-01-06 10:38:37 +0000
committerGisle Aas <gisle@activestate.com>2006-01-06 10:38:37 +0000
commit74ac850a5ee417afa60a477ea52af7a8f46a7e5a (patch)
tree542841f8cbe9f5f5a847f7a359e050c09152de11 /pod/perlrun.pod
parent2478f7a0ecfc00f4d83ec0abe7521859385d9893 (diff)
downloadperl-74ac850a5ee417afa60a477ea52af7a8f46a7e5a.tar.gz
Improve description of the -s switch.
I found the "This means you can have switches with two leading dashes." sentence introduced by change 7144 really confusing. The note after the example should make it clear enough that double dash switches can be used for those that insist. p4raw-id: //depot/perl@26669
Diffstat (limited to 'pod/perlrun.pod')
-rw-r--r--pod/perlrun.pod5
1 files changed, 2 insertions, 3 deletions
diff --git a/pod/perlrun.pod b/pod/perlrun.pod
index 6eb6bbf035..ee35b11bb0 100644
--- a/pod/perlrun.pod
+++ b/pod/perlrun.pod
@@ -771,8 +771,7 @@ X<-s>
enables rudimentary switch parsing for switches on the command
line after the program name but before any filename arguments (or before
-an argument of B<-->). This means you can have switches with two leading
-dashes (B<--help>). Any switch found there is removed from @ARGV and sets the
+an argument of B<-->). Any switch found there is removed from @ARGV and sets the
corresponding variable in the Perl program. The following program
prints "1" if the program is invoked with a B<-xyz> switch, and "abc"
if it is invoked with B<-xyz=abc>.
@@ -780,7 +779,7 @@ if it is invoked with B<-xyz=abc>.
#!/usr/bin/perl -s
if ($xyz) { print "$xyz\n" }
-Do note that B<--help> creates the variable ${-help}, which is not compliant
+Do note that a switch like B<--help> creates the variable ${-help}, which is not compliant
with C<strict refs>. Also, when using this option on a script with
warnings enabled you may get a lot of spurious "used only once" warnings.