summaryrefslogtreecommitdiff
path: root/pod/perltrap.pod
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1998-07-18 22:27:59 +0000
committerGurusamy Sarathy <gsar@cpan.org>1998-07-18 22:27:59 +0000
commit7c1f0a780f6c3c384f7ab3ab896781a54a658b5f (patch)
tree43edfdd4a2157ec9d8eb77a975b6e9d0b3e61890 /pod/perltrap.pod
parentf7ac0805bb97e1e2d7fa37a2ffc86ce9bd5c6350 (diff)
downloadperl-7c1f0a780f6c3c384f7ab3ab896781a54a658b5f.tar.gz
remove obsolete perltrap about m//g's pos() reset behavior
p4raw-id: //depot/perl@1541
Diffstat (limited to 'pod/perltrap.pod')
-rw-r--r--pod/perltrap.pod20
1 files changed, 0 insertions, 20 deletions
diff --git a/pod/perltrap.pod b/pod/perltrap.pod
index 8a3e3bcdab..1b954a357d 100644
--- a/pod/perltrap.pod
+++ b/pod/perltrap.pod
@@ -1161,26 +1161,6 @@ repeatedly, like C</x/> or C<m!x!>.
# perl5 prints: perl5
-=item * Regular Expression
-
-Under perl4 and upto version 5.003, a failed C<m//g> match used to
-reset the internal iterator, so that subsequent C<m//g> match attempts
-began from the beginning of the string. In perl version 5.004 and later,
-failed C<m//g> matches do not reset the iterator position (which can be
-found using the C<pos()> function--see L<perlfunc/pos>).
-
- $test = "foop";
- for (1..3) {
- print $1 while ($test =~ /(o)/g);
- # pos $test = 0; # to get old behavior
- }
-
- # perl4 prints: oooooo
- # perl5.004 prints: oo
-
-You may always reset the iterator yourself as shown in the commented line
-to get the old behavior.
-
=back
=head2 Subroutine, Signal, Sorting Traps