use File::Slurp qw(write_file); my $ustr = "simple unicode string \x{0434} indeed"; { open(my $FH, ">:encoding(UTF-8)", "a.txt") or die "Failed to open file - $!"; write_file($FH, $ustr) or warn "Failed write_file"; }
In reply to Re: can not use utf8 with File::Slurp
by repellent
in thread can not use utf8 with File::Slurp
by vkon
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |