[Python-checkins] CVS: python/dist/src/Include fileobject.h,2.23,2.24 moduleobject.h,2.18,2.19
Tim Peters
tim_one@users.sourceforge.net
Wed, 12 Sep 2001 22:38:57 -0700
Update of /cvsroot/python/python/dist/src/Include
In directory usw-pr-cvs1:/tmp/cvs-serv20497/python/Include
Modified Files:
fileobject.h moduleobject.h
Log Message:
SF bug [#460467] file objects should be subclassable.
Preliminary support. What's here works, but needs fine-tuning.
Index: fileobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/fileobject.h,v
retrieving revision 2.23
retrieving revision 2.24
diff -C2 -d -r2.23 -r2.24
*** fileobject.h 2001/05/14 12:17:34 2.23
--- fileobject.h 2001/09/13 05:38:55 2.24
***************
*** 10,14 ****
extern DL_IMPORT(PyTypeObject) PyFile_Type;
! #define PyFile_Check(op) ((op)->ob_type == &PyFile_Type)
extern DL_IMPORT(PyObject *) PyFile_FromString(char *, char *);
--- 10,15 ----
extern DL_IMPORT(PyTypeObject) PyFile_Type;
! #define PyFile_Check(op) PyObject_TypeCheck(op, &PyFile_Type)
! #define PyFile_CheckExact(op) ((op)->ob_type == &PyFile_Type)
extern DL_IMPORT(PyObject *) PyFile_FromString(char *, char *);
Index: moduleobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/moduleobject.h,v
retrieving revision 2.18
retrieving revision 2.19
diff -C2 -d -r2.18 -r2.19
*** moduleobject.h 2001/09/10 18:21:59 2.18
--- moduleobject.h 2001/09/13 05:38:55 2.19
***************
*** 11,14 ****
--- 11,15 ----
#define PyModule_Check(op) PyObject_TypeCheck(op, &PyModule_Type)
+ #define PyModule_CheckExact(op) ((op)->ob_type == &PyModule_Type)
extern DL_IMPORT(PyObject *) PyModule_New(char *);