summaryrefslogtreecommitdiffstats
path: root/Python/ast.c
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2013-02-09 22:16:51 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2013-02-09 22:16:51 (GMT)
commit8ad5b07ccb81f51551ac087a5409ebc85c0d16a7 (patch)
tree0496567aa3d6d37dc456da69e9b32f7da561f102 /Python/ast.c
parent151699a202e6213c1f02b37605a033975ae52307 (diff)
parentc73c561181c3ea3bf15c908a827878e1450a5ac6 (diff)
downloadcpython-8ad5b07ccb81f51551ac087a5409ebc85c0d16a7.zip
cpython-8ad5b07ccb81f51551ac087a5409ebc85c0d16a7.tar.gz
cpython-8ad5b07ccb81f51551ac087a5409ebc85c0d16a7.tar.bz2
Issue #17173: Remove uses of locale-dependent C functions (isalpha() etc.) in the interpreter.
I've left a couple of them in: zlib (third-party lib), getaddrinfo.c (doesn't include Python.h, and probably obsolete), _sre.c (legitimate use for the re.LOCALE flag), mpdecimal (needs to build without Python.h).
Diffstat (limited to 'Python/ast.c')
-rw-r--r--Python/ast.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/ast.c b/Python/ast.c
index 5060303..f0a3917 100644
--- a/Python/ast.c
+++ b/Python/ast.c
@@ -3761,7 +3761,7 @@ parsestr(struct compiling *c, const node *n, int *bytesmode)
int quote = Py_CHARMASK(*s);
int rawmode = 0;
int need_encoding;
- if (isalpha(quote)) {
+ if (Py_ISALPHA(quote)) {
while (!*bytesmode || !rawmode) {
if (quote == 'b' || quote == 'B') {
quote = *++s;