Files can only contain bytes, but you're printing something that's obviously not a byte.
You need to convert the text to bytes ("encode" it), or tell Perl to do it for you.
open(my $fh, '>:encoding(UTF-8)', $qfn) or die("Can't create output file \"$qfn\": $!\n"); print $fh $text;
In reply to Re: Wide character in print at
by ikegami
in thread Wide character in print at
by paragkalra
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |