Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 302e790

Browse files
committed
use identifier api
1 parent b4dcb10 commit 302e790

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Python/ceval.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1837,10 +1837,11 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throwflag)
18371837
if (PyGen_CheckExact(x)) {
18381838
retval = _PyGen_Send((PyGenObject *)x, u);
18391839
} else {
1840+
_Py_IDENTIFIER(send);
18401841
if (u == Py_None)
18411842
retval = PyIter_Next(x);
18421843
else
1843-
retval = PyObject_CallMethod(x, "send", "O", u);
1844+
retval = _PyObject_CallMethodId(x, &PyId_send, "O", u);
18441845
}
18451846
Py_DECREF(u);
18461847
if (!retval) {

0 commit comments

Comments
 (0)