FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

PyModule_Check() now checks for subtype of module, as it should. · python/cpython@b875509 · GitHub

Repository navigation

Commit b875509

Browse files
committed
PyModule_Check() now checks for subtype of module, as it should.
1 parent d6e40e2 commit b875509

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎Include/moduleobject.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ extern "C" {
99

1010
extern DL_IMPORT(PyTypeObject) PyModule_Type;
1111

12-
#define PyModule_Check(op) ((op)->ob_type == &PyModule_Type)
12+
#define PyModule_Check(op) PyObject_TypeCheck(op, &PyModule_Type)
1313

1414
extern DL_IMPORT(PyObject *) PyModule_New(char *);
1515
extern DL_IMPORT(PyObject *) PyModule_GetDict(PyObject *);

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL