Mercurial > cpython-lru_cache-weakref
diff Python/ast.c @ 74444:fe40a87484cc
use helpful PyUnicode_IS_ASCII macro
| author | Benjamin Peterson <benjamin@python.org> |
|---|---|
| date | Mon, 16 Jan 2012 09:49:20 -0500 |
| parents | f5214817ed57 |
| children | 5ef589e38985 |
line wrap: on
line diff
--- a/Python/ast.c Mon Jan 16 09:47:42 2012 -0500 +++ b/Python/ast.c Mon Jan 16 09:49:20 2012 -0500 @@ -537,7 +537,7 @@ assert(PyUnicode_IS_READY(id)); /* Check whether there are non-ASCII characters in the identifier; if so, normalize to NFKC. */ - if (PyUnicode_MAX_CHAR_VALUE((PyUnicodeObject *)id) >= 128) { + if (PyUnicode_IS_ASCII(id)) { PyObject *m = PyImport_ImportModuleNoBlock("unicodedata"); PyObject *id2; if (!m)
