diff Python/ast.c @ 82110:38830281d43b 3.2

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).
author Antoine Pitrou <solipsis@pitrou.net>
date Sat, 09 Feb 2013 23:11:27 +0100
parents 4a343636c8ca
children 305210a08fc9 c08bcf5302ec
line wrap: on
line diff
--- a/Python/ast.c	Sat Feb 09 22:37:22 2013 +0200
+++ b/Python/ast.c	Sat Feb 09 23:11:27 2013 +0100
@@ -3305,7 +3305,7 @@
     int quote = Py_CHARMASK(*s);
     int rawmode = 0;
     int need_encoding;
-    if (isalpha(quote)) {
+    if (Py_ISALPHA(quote)) {
         if (quote == 'b' || quote == 'B') {
             quote = *++s;
             *bytesmode = 1;