From 09282aab28fd03f67c65d4e123314a9579f592b5 Mon Sep 17 00:00:00 2001 From: Mohammad S Anwar Date: Wed, 9 May 2018 11:53:56 +0100 Subject: [PATCH] Proposed fix to warning about "Wide character in print". --- lib/Path/Class/File.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/Path/Class/File.pm b/lib/Path/Class/File.pm index b36b340..4d781f8 100644 --- a/lib/Path/Class/File.pm +++ b/lib/Path/Class/File.pm @@ -114,6 +114,7 @@ sub spew { my $iomode = $args{iomode} || 'w'; my $fh = $self->open( $iomode ) or croak "Can't write to $self: $!"; + binmode $fh, ':utf8'; if (ref($_[0]) eq 'ARRAY') { # Use old-school for loop to avoid copying.