Pathologically Eclectic Rubbish Lister | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Short answer: because Unicode and locales don't mix. Long answer: Perl's support for locales comes from a time before the whole encoding/decoding business and Unicode support. So if locales are active, the locale-sensitive parts expect to act on bytes, not on decoded strings. Since the locale is not ISO-8859-1 but UTF-8, encoding to Latin-1 doesn't fix it for you. If anything, you'd need to encode to UTF-8 to see the \w matching ä, but even then I don't see it matching. So either my understanding of locales is very wrong, or perl is broken (or a mixture thereof). In reply to Re^3: Regex Matching Unicode and Regex Classes
by moritz
|
|