The Perl 6 Librarian writes
>=head1 DESCRIPTION
>
>This RFC contains two proposed changes. First, as it is common to want to
>removed newlines upon reading a file,
>
> while (chomp(<FILEHANDLE>)) {
> . . .
> }
>
>should become the equivalent of
>
> while (<FILEHANDLE>) {
> chomp;
> . . .
> }
>
>where the various equivalent constructions would, of course, work as
expected.
>
>Second, as it seems common for someone learning perl to expect
>
> $without_newline = chomp($previous_form);
>
>to put a copy of the text in C<$previous_form>, sans newline, into
>C<$without_newline> while not modifying C<$previous_form>, Perl should
>do just that.
>
>C<chomp()> called in void context would remove the newline
>from the variable (or members of the list) upon which it was called.
>C<chomp()> called in a scalar context would leave its argument variable
>untouched and instead return a C<chomp()>ed version of that variable's
>contents. Likewise and furthermore for other contexts.
chomp good. nice word. me like. me want chomp strings and file handles
too.
I think the people we actualy need to hear from are those who are actualy
using the return value from chomp, as they are the only ones who could be
negitivly affected by this proposal.
As to what we look to match ($/, $FH->IRS,$SOME_WACKEY_NEW_VAR) as Larry
pints out that's far from knowable right now, so like, we'll firgure that
out when the time comes.
Also, I don't want to quote anyone - but: I don't like the "We can focus on
ripping things up" attitude that some of us have been justifying by assuming
that Larry will sort though the myriad of conflicting RFC and comments, tell
us which are Perl and set us about implementing them.
My understanding is that perl6 is the Perl community's rewrite of the
program (and -to some degree- the language).
So, kids, whatcha doing with that return value? (the number of characters
removed by the operation)?
And, oh yeah, ++Ted.
-Corwin