From: Karen Etheridge Date: Sat, 5 Oct 2019 17:50:12 +0000 (-0700) Subject: set filehandle encodings in a shorter way X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=67fcad436dd54f9750f052568bb3961d7808c026;p=p5sagit%2FSub-Name.git set filehandle encodings in a shorter way --- diff --git a/t/exotic_names.t b/t/exotic_names.t index 06d6484..d5f87f2 100644 --- a/t/exotic_names.t +++ b/t/exotic_names.t @@ -12,12 +12,7 @@ BEGIN { $^P |= 0x210 } # a heuristic with ambiguous eval and looking for octets in the stash use if "$]" >= 5.016, feature => 'unicode_eval'; -if ("$]" >= 5.008) { - my $builder = Test::More->builder; - binmode $builder->output, ":encoding(utf8)"; - binmode $builder->failure_output, ":encoding(utf8)"; - binmode $builder->todo_output, ":encoding(utf8)"; -} +use if "$]" >= 5.008, open => ':std', ':encoding(UTF-8)'; # force stdin, stdout, stderr into utf8 sub compile_named_sub { my ( $fullname, $body ) = @_;