Is it correct that even in a German locale, the #regex '[A-Z]' does not match umlauts ÄÖÜ in #Rstats :rstats: ? My colleague tested it on Stata and it does. 🙄

@sascha_wolfer I think this may depend on regex engine, but I thought the range operator translated to ASCII representation so the range would make sense.

@psanker @sascha_wolfer Maybe there are implementations that do this (Perl ensures consistent behavior for the special ranges A-Z, a-z, 0-9, and any subranges of these), but according to POSIX, in any locale other than POSIX, “a range expression has unspecified behavior.” Better use [[:upper:]] or something equivalent.

Sign in to participate in the conversation
CleverLibre Social

CleverLibre Social is an inclusive social instance for open discussion, learning, and community.
All cultures welcome.
Hate speech and harassment strictly forbidden.