With Encode::encode
there are different ways to handle malformed data.
Does for binmode like binmode STDOUT ":encoding( $encoding_out )"
also exist possibilities to handle malformed data?
With Encode::encode
there are different ways to handle malformed data.
Does for binmode like binmode STDOUT ":encoding( $encoding_out )"
also exist possibilities to handle malformed data?
Copyright © 2021 Jogjafile Inc.
Yes, there's
$PerlIO::encoding::fallback
. You can assign the wanted “check” argument to that variable. When you then push a PerlIO layer onto a filehandle, the current value from that variable is saved for that layers failure behavior. E.g.: