This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
PerlIO::encoding: Use Encode::ONLY_PRAGMA_WARNINGS in fallback by default
authorPali <pali@cpan.org>
Sat, 1 Jul 2017 10:34:25 +0000 (12:34 +0200)
committerTony Cook <tony@develop-help.com>
Sun, 24 Feb 2019 23:56:06 +0000 (10:56 +1100)
This would enable to respect utf8 warnings enabled/disabled by pramga
warnings when processing filehandle with :encoding layer.

ext/PerlIO-encoding/encoding.pm

index 3d740b1..a9f360d 100644 (file)
@@ -14,7 +14,7 @@ require XSLoader;
 XSLoader::load();
 
 our $fallback =
-    Encode::PERLQQ()|Encode::WARN_ON_ERR()|Encode::STOP_AT_PARTIAL();
+    Encode::PERLQQ()|Encode::WARN_ON_ERR()|Encode::ONLY_PRAGMA_WARNINGS()|Encode::STOP_AT_PARTIAL();
 
 1;
 __END__