commit | e266d3e804b0f27aa4f63d321372ed926cc45aab | [log] [tgz] |
---|---|---|
author | Benjamin Peterson <benjamin@python.org> | Tue Apr 06 03:34:09 2010 +0000 |
committer | Benjamin Peterson <benjamin@python.org> | Tue Apr 06 03:34:09 2010 +0000 |
tree | 971840d4b4d3741fe1cb0f8e3de8978f916db881 | |
parent | 021f334b9fe620a33b286ea15ab9f45e32938100 [diff] [blame] |
ready _sre types
diff --git a/Modules/_sre.c b/Modules/_sre.c index 2cf9705..eda30c4 100644 --- a/Modules/_sre.c +++ b/Modules/_sre.c
@@ -3876,8 +3876,9 @@ PyObject* x; /* Patch object types */ - Pattern_Type.ob_type = Match_Type.ob_type = - Scanner_Type.ob_type = &PyType_Type; + if (PyType_Ready(&Pattern_Type) || PyType_Ready(&Match_Type) || + PyType_Ready(&Scanner_Type)) + return; m = Py_InitModule("_" SRE_MODULE, _functions); if (m == NULL)