diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1999-03-24 10:15:00 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-03-24 10:15:00 +0000 |
commit | fa08c05b640ede69b33d2ae5b23634d6e5b0865c (patch) | |
tree | e4917a4652007919bf170ea67d0d42d77e17079a /pod/perlop.pod | |
parent | 0650ba1c71b86de5b30e0e7971fefc789a9bfbfc (diff) | |
download | perl-fa08c05b640ede69b33d2ae5b23634d6e5b0865c.tar.gz |
doc tweak suggested by M.J.T. Guy <mjtg@cus.cam.ac.uk>
p4raw-id: //depot/perl@3151
Diffstat (limited to 'pod/perlop.pod')
-rw-r--r-- | pod/perlop.pod | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/pod/perlop.pod b/pod/perlop.pod index 313ed583a5..f70311b8e1 100644 --- a/pod/perlop.pod +++ b/pod/perlop.pod @@ -830,10 +830,12 @@ Examples: ($one,$five,$fifteen) = (`uptime` =~ /(\d+\.\d+)/g); # scalar context - $/ = ""; $* = 1; # $* deprecated in modern perls - while (defined($paragraph = <>)) { - while ($paragraph =~ /[a-z]['")]*[.!?]+['")]*\s/g) { - $sentences++; + { + local $/ = ""; + while (defined($paragraph = <>)) { + while ($paragraph =~ /[a-z]['")]*[.!?]+['")]*\s/g) { + $sentences++; + } } } print "$sentences\n"; |