New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
\n should be 0x0d 0x0a on win32 #2406
Comments
From patrick.abisalloum@gmail.comOn windows 7 and vista using "\n" does not produce \r\n The following my $file = open('foo.txt', :w); produces a file containing the bytes 61 0a 62 0a The expected bytes are 61 0d 0a 62 0d 0a A current work around is to use $file.print("a\r\nb\r\n"); |
From wbiker@gmx.atHi, Following script on Windows: use v6; my $fh = open('test.txt', :w); $fh.say("hello"); $fh.close; produced following file: helloPerl6 Also on Windows say uses \n instead of \r\n THX |
From @mattnOn 2015-3月-08 日 23:41:49, wbiker@gmx.at wrote:
I think using \r\n is non-sense in 2015. We can use \n instead of \r\n. Why need \r\n? Let's throw away such as compatibility with Perl5. Many perl users on windows have been plagued by differences of each OS. |
The RT System itself - Status changed from 'new' to 'open' |
From wbiker@gmx.athmm. greetings On 8 October 2015 at 17:49, Yasuhiro Matsumoto via RT <
|
From @jnthnOn Fri Apr 15 12:06:47 2011, patrickas wrote:
Now \n in strings is "magical": it will default to CRLF on Windows, and just LF elsewhere (you can see what $?NL contains to check). It can be controlled by the newline pragma when this default is not appropriate, tests for which are in S16-io/newline.t. Thanks, Jonathan |
@jnthn - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#88674 (status was 'resolved')
Searchable as RT88674$
The text was updated successfully, but these errors were encountered: