[Python-checkins] python/dist/src/Modules collectionsmodule.c, 1.14, 1.15 (original) (raw)

rhettinger at users.sourceforge.net rhettinger at users.sourceforge.net
Tue May 18 14:15:08 EDT 2004


Update of /cvsroot/python/python/dist/src/Modules In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1812

Modified Files: collectionsmodule.c Log Message: Make type check work with subclasses

Index: collectionsmodule.c

RCS file: /cvsroot/python/python/dist/src/Modules/collectionsmodule.c,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** collectionsmodule.c 12 May 2004 20:55:42 -0000 1.14 --- collectionsmodule.c 18 May 2004 18:15:03 -0000 1.15


*** 588,592 **** int i, b, vs, ws, minlen, cmp=-1;

! if (v->ob_type != &deque_type || w->ob_type != &deque_type) { Py_INCREF(Py_NotImplemented); return Py_NotImplemented; --- 588,593 ---- int i, b, vs, ws, minlen, cmp=-1;

! if (!PyObject_TypeCheck(v, &deque_type) || ! !PyObject_TypeCheck(w, &deque_type)) { Py_INCREF(Py_NotImplemented); return Py_NotImplemented;



More information about the Python-checkins mailing list