Patch #494384: Disable more Unicode API if Unicode is not used.

This commit is contained in:
Martin v. Löwis 2001-12-18 22:36:40 +00:00
parent a255a72f0a
commit 8d3ce5a6b3

View file

@ -1362,6 +1362,7 @@ eval_frame(PyFrameObject *f)
s[len-1] != ' ') s[len-1] != ' ')
PyFile_SoftSpace(w, 0); PyFile_SoftSpace(w, 0);
} }
#ifdef Py_USING_UNICODE
else if (PyUnicode_Check(v)) { else if (PyUnicode_Check(v)) {
Py_UNICODE *s = PyUnicode_AS_UNICODE(v); Py_UNICODE *s = PyUnicode_AS_UNICODE(v);
int len = PyUnicode_GET_SIZE(v); int len = PyUnicode_GET_SIZE(v);
@ -1370,6 +1371,7 @@ eval_frame(PyFrameObject *f)
s[len-1] != ' ') s[len-1] != ' ')
PyFile_SoftSpace(w, 0); PyFile_SoftSpace(w, 0);
} }
#endif
} }
Py_DECREF(v); Py_DECREF(v);
Py_XDECREF(stream); Py_XDECREF(stream);