]> git.donarmstrong.com Git - perltidy.git/commit
fix Windows EOL translation error with UTF-8
authorRoy Ivy III <rivy.dev@gmail.com>
Sat, 9 Mar 2019 05:31:26 +0000 (23:31 -0600)
committerRoy Ivy III <rivy.dev@gmail.com>
Sat, 9 Mar 2019 08:23:29 +0000 (02:23 -0600)
commit5c74780779ad5ec9e6ba0f3e1a629539d902931b
treea3fb15bd540a6e4beaebb8c31122452dc89bf202
parentade018441d7bea360d0764864008066d572360d3
fix Windows EOL translation error with UTF-8

.# Discussion

When using `binmode ... ":encoding(UTF8)"`, the CRLF translation layer is left in-place.
As used prior to this commit, on Windows machines, this `binmode` setting causes
the output file to be converted to "DOS" CRLF line endings regardless of other settings.

`binmode ... ":raw:encoding(UTF8)"` will enable UTF-8 without the CRLF translation layer.
lib/Perl/Tidy.pm
lib/Perl/Tidy/LineSink.pm