If you were feeding the 'uc' operator a string of utf8 bytes from your editor which perl had not been informed was intended as unicode, then perl would apply ascii uppercasing rules to that string of bytes. Now that you have the "use utf8" in your file, I think you'll find that 'uc' works properly on that string. But, you'll also find that perl warns you if you try to print that string, because in the default configuration the output streams expect bytes as input. You can either use binmode(STDOUT, 'encoding(UTF-8)') to declare that you intend to always write unicode to the file handle, or remember to encode the string before printing.
Full unicode support exists in perl, but yeah it's kind of a learning curve to find it :-( But that's the price we pay for full multi-decade back-compat.
In reply to Re^3: Memory Leak with XS but not pure C
by NERDVANA
in thread Memory Leak with XS but not pure C
by FrankFooty
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |