From: Benjamin Peterson Date: Wed, 31 Oct 2012 03:27:52 +0000 (-0400) Subject: merge 3.2 (#16369) X-Git-Tag: v3.3.1rc1~723 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e8ea97fffb591cd71090d0f3114bf1d3bcd31454;p=python merge 3.2 (#16369) --- e8ea97fffb591cd71090d0f3114bf1d3bcd31454 diff --cc Objects/object.c index f41718424d,28bb9c1e46..949e7dc7f3 --- a/Objects/object.c +++ b/Objects/object.c @@@ -1708,8 -1645,29 +1708,32 @@@ _Py_ReadyTypes(void if (PyType_Ready(&PyZip_Type) < 0) Py_FatalError("Can't initialize zip type"); + if (PyType_Ready(&_PyNamespace_Type) < 0) + Py_FatalError("Can't initialize namespace type"); ++ + if (PyType_Ready(&PyCapsule_Type) < 0) + Py_FatalError("Can't initialize capsule type"); + + if (PyType_Ready(&PyLongRangeIter_Type) < 0) + Py_FatalError("Can't initialize long range iterator type"); + + if (PyType_Ready(&PyCell_Type) < 0) + Py_FatalError("Can't initialize cell type"); + + if (PyType_Ready(&PyInstanceMethod_Type) < 0) + Py_FatalError("Can't initialize instance method type"); + + if (PyType_Ready(&PyClassMethodDescr_Type) < 0) + Py_FatalError("Can't initialize class method descr type"); + + if (PyType_Ready(&PyMethodDescr_Type) < 0) + Py_FatalError("Can't initialize method descr type"); + + if (PyType_Ready(&PyCallIter_Type) < 0) + Py_FatalError("Can't initialize call iter type"); + + if (PyType_Ready(&PySeqIter_Type) < 0) + Py_FatalError("Can't initialize sequence iterator type"); } diff --cc Objects/unicodeobject.c index 6c8fe2d865,35b424e33a..f61f9d0df1 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@@ -14167,14 -10080,11 +14167,20 @@@ int _PyUnicode_Init(void PyType_Ready(&EncodingMapType); + if (PyType_Ready(&PyFieldNameIter_Type) < 0) + Py_FatalError("Can't initialize field name iterator type"); + + if (PyType_Ready(&PyFormatterIter_Type) < 0) + Py_FatalError("Can't initialize formatter iter type"); ++ +#ifdef HAVE_MBCS + winver.dwOSVersionInfoSize = sizeof(winver); + if (!GetVersionEx((OSVERSIONINFO*)&winver)) { + PyErr_SetFromWindowsErr(0); + return -1; + } +#endif + return 0; } /* Finalize the Unicode implementation */