[Python-Dev] String module
Raymond Hettinger
python@rcn.com
Thu, 30 May 2002 15:48:32 -0400
From: "Guido van Rossum" <guido@python.org>
> Thanks! But now we have a diverging set of isxxx methods for 8-bit
> strings and Unicode. I really don't know what the equivalent of these
> (ispunct, iscntrl, isgraph, isprint) is in Unicode -- maybe MAL or MvL
> know? Unicode also has a wider definition of digits; do we want to
> extend isxdigit() for that? (Probably not, but I'm not sure.)
I'll spend some time with the big Unicode 3.0 book this evening
and chat with some Unicode techno-weenies. When I've got
an answer will add the unicodeobject.c methods to the patch.
> Someone commented that isxdigit is a poor name. OTOH it's what C
> uses. I'm not sure what to say.
I concur. I had to look it up on google to make sure in meant
what I surmised it meant. ishexdigit() is more explicit.
Besides, C naming conventions aren't exactly role models for clarity ;)
While we're at it:
isgraph() --> isvisible()
iscntrl() --> iscontrol()
isprint() --> isprintable()
I'm sure everyone will have an opinion or two.
Raymond Hettinger