no need to own an argument passed into a Python function
authorStefan Behnel <scoder@users.berlios.de>
Fri, 10 Dec 2010 22:57:30 +0000 (23:57 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Fri, 10 Dec 2010 22:57:30 +0000 (23:57 +0100)
Cython/Compiler/ExprNodes.py

index f66d6abdae6d0d0b1fafea8ef6fd355f93ab29d5..1c3939f7ee337898124b616bd40c6d47ccf2c33f 100755 (executable)
@@ -8347,13 +8347,7 @@ static CYTHON_INLINE PyObject *__CyGenerator_SendEx(struct __CyGenerator *self,
 
 static PyObject *__CyGenerator_Next(PyObject *self)
 {
-    struct __CyGenerator *generator = (struct __CyGenerator *) self;
-    PyObject *retval;
-
-    Py_INCREF(Py_None);
-    retval = __CyGenerator_SendEx(generator, Py_None);
-    Py_DECREF(Py_None);
-    return retval;
+    return __CyGenerator_SendEx((struct __CyGenerator *) self, Py_None);
 }
 
 static PyObject *__CyGenerator_Send(PyObject *self, PyObject *value)