diff options
author | Guido van Rossum <guido@python.org> | 2001-09-10 18:21:59 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2001-09-10 18:21:59 (GMT) |
commit | b8755093109692d1708b87268c80a65b473e798e (patch) | |
tree | 95561ebcc0c009514f491a4e1ab530a7bbb02217 /Include | |
parent | d6e40e24f820ff5c6e9456b7a96868ef2a3d86fe (diff) | |
download | cpython-b8755093109692d1708b87268c80a65b473e798e.zip cpython-b8755093109692d1708b87268c80a65b473e798e.tar.gz cpython-b8755093109692d1708b87268c80a65b473e798e.tar.bz2 |
PyModule_Check() now checks for subtype of module, as it should.
Diffstat (limited to 'Include')
-rw-r--r-- | Include/moduleobject.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Include/moduleobject.h b/Include/moduleobject.h index 00a23aa..8c3ba61 100644 --- a/Include/moduleobject.h +++ b/Include/moduleobject.h @@ -9,7 +9,7 @@ extern "C" { extern DL_IMPORT(PyTypeObject) PyModule_Type; -#define PyModule_Check(op) ((op)->ob_type == &PyModule_Type) +#define PyModule_Check(op) PyObject_TypeCheck(op, &PyModule_Type) extern DL_IMPORT(PyObject *) PyModule_New(char *); extern DL_IMPORT(PyObject *) PyModule_GetDict(PyObject *); |