[Python-checkins] CVS: python/dist/src/Include stringobject.h,2.29,2.30 tupleobject.h,2.25,2.26 unicodeobject.h,2.31,2.32
Guido van Rossum
gvanrossum@users.sourceforge.net
Wed, 29 Aug 2001 20:08:10 -0700
Update of /cvsroot/python/python/dist/src/Include
In directory usw-pr-cvs1:/tmp/cvs-serv25513
Modified Files:
stringobject.h tupleobject.h unicodeobject.h
Log Message:
Make the Py<type>_Check() macro use PyObject_TypeCheck().
Index: stringobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/stringobject.h,v
retrieving revision 2.29
retrieving revision 2.30
diff -C2 -d -r2.29 -r2.30
*** stringobject.h 2001/08/24 18:32:06 2.29
--- stringobject.h 2001/08/30 03:08:07 2.30
***************
*** 52,56 ****
extern DL_IMPORT(PyTypeObject) PyString_Type;
! #define PyString_Check(op) ((op)->ob_type == &PyString_Type)
extern DL_IMPORT(PyObject *) PyString_FromStringAndSize(const char *, int);
--- 52,56 ----
extern DL_IMPORT(PyTypeObject) PyString_Type;
! #define PyString_Check(op) PyObject_TypeCheck(op, &PyString_Type)
extern DL_IMPORT(PyObject *) PyString_FromStringAndSize(const char *, int);
Index: tupleobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/tupleobject.h,v
retrieving revision 2.25
retrieving revision 2.26
diff -C2 -d -r2.25 -r2.26
*** tupleobject.h 2001/05/28 22:30:07 2.25
--- tupleobject.h 2001/08/30 03:08:07 2.26
***************
*** 27,31 ****
extern DL_IMPORT(PyTypeObject) PyTuple_Type;
! #define PyTuple_Check(op) ((op)->ob_type == &PyTuple_Type)
extern DL_IMPORT(PyObject *) PyTuple_New(int size);
--- 27,31 ----
extern DL_IMPORT(PyTypeObject) PyTuple_Type;
! #define PyTuple_Check(op) PyObject_TypeCheck(op, &PyTuple_Type)
extern DL_IMPORT(PyObject *) PyTuple_New(int size);
Index: unicodeobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/unicodeobject.h,v
retrieving revision 2.31
retrieving revision 2.32
diff -C2 -d -r2.31 -r2.32
*** unicodeobject.h 2001/08/17 18:39:24 2.31
--- unicodeobject.h 2001/08/30 03:08:07 2.32
***************
*** 373,377 ****
extern DL_IMPORT(PyTypeObject) PyUnicode_Type;
! #define PyUnicode_Check(op) (((op)->ob_type == &PyUnicode_Type))
/* Fast access macros */
--- 373,377 ----
extern DL_IMPORT(PyTypeObject) PyUnicode_Type;
! #define PyUnicode_Check(op) PyObject_TypeCheck(op, &PyUnicode_Type)
/* Fast access macros */