mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
Add API for static strings, primarily good for identifiers.
Thanks to Konrad Schöbel and Jasper Schulz for helping with the mass-editing.
This commit is contained in:
parent
67df285a33
commit
afe55bba33
50 changed files with 578 additions and 240 deletions
|
|
@ -654,7 +654,9 @@ tee(PyObject *self, PyObject *args)
|
|||
copyable = it;
|
||||
PyTuple_SET_ITEM(result, 0, copyable);
|
||||
for (i=1 ; i<n ; i++) {
|
||||
copyable = PyObject_CallMethod(copyable, "__copy__", NULL);
|
||||
_Py_identifier(__copy__);
|
||||
|
||||
copyable = _PyObject_CallMethodId(copyable, &PyId___copy__, NULL);
|
||||
if (copyable == NULL) {
|
||||
Py_DECREF(result);
|
||||
return NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue