diff options
author | Victor Stinner <vstinner@python.org> | 2023-06-01 23:33:17 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-01 23:33:17 (GMT) |
commit | ef300937c2a1b3ebe19c2835f3b46585825c1e1f (patch) | |
tree | 34f151a390fb946ff985ed98e6c1bd096c4d090b /Python/_warnings.c | |
parent | cbb9ba844f15f2b8127028e6dfd4681b2cb2376f (diff) | |
download | cpython-ef300937c2a1b3ebe19c2835f3b46585825c1e1f.zip cpython-ef300937c2a1b3ebe19c2835f3b46585825c1e1f.tar.gz cpython-ef300937c2a1b3ebe19c2835f3b46585825c1e1f.tar.bz2 |
gh-92536: Remove PyUnicode_READY() calls (#105210)
Since Python 3.12, PyUnicode_READY() does nothing and always
returns 0.
Diffstat (limited to 'Python/_warnings.c')
-rw-r--r-- | Python/_warnings.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/Python/_warnings.c b/Python/_warnings.c index 54fa5c5..69fa04e 100644 --- a/Python/_warnings.c +++ b/Python/_warnings.c @@ -533,9 +533,6 @@ show_warning(PyThreadState *tstate, PyObject *filename, int lineno, Py_UCS4 ch; PyObject *truncated; - if (PyUnicode_READY(sourceline) < 1) - goto error; - kind = PyUnicode_KIND(sourceline); data = PyUnicode_DATA(sourceline); len = PyUnicode_GET_LENGTH(sourceline); |