mirror of
https://github.com/python/cpython.git
synced 2026-01-06 15:32:22 +00:00
gh-136300: Modify C tests to conform to PEP-737 (GH-136301)
- Use %T format specifier instead of %s and Py_TYPE(x)->tp_name. - Remove legacy %.200s format specifier for truncating type names. Co-authored-by: Victor Stinner <vstinner@python.org>
This commit is contained in:
parent
3343fce05a
commit
7de8ea7be6
5 changed files with 5 additions and 9 deletions
|
|
@ -1855,8 +1855,7 @@ ndarray_subscript(PyObject *op, PyObject *key)
|
|||
|
||||
type_error:
|
||||
PyErr_Format(PyExc_TypeError,
|
||||
"cannot index memory using \"%.200s\"",
|
||||
Py_TYPE(key)->tp_name);
|
||||
"cannot index memory using \"%T\"", key);
|
||||
err_occurred:
|
||||
Py_DECREF(nd);
|
||||
return NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue