mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
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).
This commit is contained in:
commit
c73c561181
11 changed files with 19 additions and 17 deletions
|
@ -4,7 +4,6 @@
|
|||
#include "Python.h"
|
||||
#include "importdl.h"
|
||||
|
||||
#include <ctype.h> /* for isdigit() */
|
||||
#include <errno.h> /* for global errno */
|
||||
#include <string.h> /* for strerror() */
|
||||
#include <stdlib.h> /* for malloc(), free() */
|
||||
|
@ -141,7 +140,7 @@ aix_loaderror(const char *pathname)
|
|||
if (nerr == load_errtab[j].errNo && load_errtab[j].errstr)
|
||||
ERRBUF_APPEND(load_errtab[j].errstr);
|
||||
}
|
||||
while (isdigit(Py_CHARMASK(*message[i]))) message[i]++ ;
|
||||
while (Py_ISDIGIT(Py_CHARMASK(*message[i]))) message[i]++ ;
|
||||
ERRBUF_APPEND(message[i]);
|
||||
ERRBUF_APPEND("\n");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue