summaryrefslogtreecommitdiff
path: root/pod
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1999-05-07 08:07:02 +0000
committerGurusamy Sarathy <gsar@cpan.org>1999-05-07 08:07:02 +0000
commit4c5a6083a6f92a8003034d6119c72e8d828e4613 (patch)
treea4830fa12e559e5ae09e8a508784ae04af935213 /pod
parent787eafbd5502f34cb6300ce384514251ed273d04 (diff)
downloadperl-4c5a6083a6f92a8003034d6119c72e8d828e4613.tar.gz
From: Dan Sugalski <sugalskd@osshe.edu>
Date: Mon, 05 Apr 1999 15:38:42 -0700 Message-Id: <3.0.6.32.19990405153842.0367b650@ous.edu> Subject: Re: chomp fails with $/ in fixed-length record mode -- From: Roderick Schertler <roderick@argon.org> Date: Tue, 06 Apr 1999 21:11:37 -0400 Message-ID: <2795.923447497@eeyore.ibcinc.com> Subject: Re: chomp fails with $/ in fixed-length record mode p4raw-id: //depot/perl@3319
Diffstat (limited to 'pod')
-rw-r--r--pod/perlfunc.pod4
1 files changed, 3 insertions, 1 deletions
diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod
index c973d0c367..b2231a3a87 100644
--- a/pod/perlfunc.pod
+++ b/pod/perlfunc.pod
@@ -546,7 +546,9 @@ number of characters removed from all its arguments. It's often used to
remove the newline from the end of an input record when you're worried
that the final record may be missing its newline. When in paragraph
mode (C<$/ = "">), it removes all trailing newlines from the string.
-If VARIABLE is omitted, it chomps C<$_>. Example:
+When in slurp mode (C<$/ = undef>) or fixed-length record mode (C<$/> is
+a reference to an integer or the like, see L<perlvar>) chomp() won't
+remove anything. If VARIABLE is omitted, it chomps C<$_>. Example:
while (<>) {
chomp; # avoid \n on last field