in reply to Re^2: Seeking Perl docs about how UTF8 flag propagates
in thread Seeking Perl docs about how UTF8 flag propagates
If that's the intent
It is. Code that behaves differently based on the internal storage format is said to suffer from The Unicode Bug.
it doesn't always work in practice
True. Notably, the operators that accept file names. And of course, some XS modules.
utf8::upgrade and utf8::downgrade can be used to work around these bugs.
certain functions (e.g., lc) change their behavior depending on how the flag is set.
lc, uc and the regex engine were fixed in 5.14, released in 2011 (12 years ago).
To get the fix, you need to use use v5.14;, or use feature qw( unicode_strings ); more specifically.
(The feature actually appeared in 5.12, but it didn't fix as many things in 5.12 as in 5.14, so I pretend it was added in 5.14.)
|
---|