Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^2: How is the default "Input Record Separator" set?

by haukex (Archbishop)
on Mar 15, 2021 at 18:56 UTC ( [id://11129709]=note: print w/replies, xml ) Need Help??


in reply to Re: How is the default "Input Record Separator" set?
in thread How is the default "Input Record Separator" set?

In this case, I have 2 different perl implementations installed, one being cygwin (perl version 5.26, which is the one that keeps the CR) and the other being a standalone perl (perl v5.8.8, which is the one that eliminates the CR).

It's been a while since I worked with cygwin, but I assume that it's acting like a *NIX system would and not loading the :crlf layer by default - try perl -le "print for PerlIO::get_layers(*STDIN)" at the command line to check.

Note that you can be really explicit about the fact that you want the :crlf layer to be loaded: try and see if open my $makefileToProcess, "<:raw:crlf", ... makes it work on both Perls.

Also note that 5.8.8 is now over 15 years old. You probably want to consider upgrading, see Strawberry Perl.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11129709]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2024-03-29 10:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found