in reply to
alter $/ - but why?
To make your code even more portable, you should replace every "\n" by "\012" (except those "\n" that are printed).
If you don't, your code would not run properly on Mac systems.
Comment on
Re: alter $/ - but why?
Replies are listed 'Best First'.
Re^2: alter $/ - but why?
by
bart
(Canon)
on Aug 03, 2005 at 20:38 UTC
Well, yes and no... actually the tests for bare
"\n"
and
"\r"
would work, but the test for
"\r\n"
would fail (at least, in MacPerl on MacOS Classic). It is advisable to replace
"\r\n"
and
/\r\n/
with
"\015\012"
and
/\015\012/
, respectively.
[reply]
[d/l]
[select]
In Section
Seekers of Perl Wisdom