On Wednesday 14 November 2007 01:33:54 Jan Kundrát wrote:
> Steve Long wrote:
> >> Is [[:alpha:]] locale-safe?
> >
> > Yes, all POSIX character classes listed here are:
> > http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap07.html
>
> Thanks for a nice link. If I read section 7.3.1 correctly, [[:alpha:]]
> always contains those letters, but might contain more, depending on the
> locale. So it's probably very minor point, but as long as the script
> runs with user-provided locale, one should be explicit here. Or am I
> missing something here?

If you think [a-zA-Z] is being explicit then you are clearly missing 
something. E.g. if you google for the estonian alphabet you'll see a lot of 
ansi letters are after z in that alphabet. So on estonian locales those 
letters won't be included in [a-z] but they will be included in [:alpha:].

-- 
Bo Andresen

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to