Content-Length: 1109 | pFad | http://github.com/python/cpython/commit/3a35b62ea003182c643516098cc781944d425800.patch

B1 From 3a35b62ea003182c643516098cc781944d425800 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Tue, 3 May 2022 22:40:20 +0200 Subject: [PATCH] gh-91321: Fix PyModuleDef_HEAD_INIT on C++ (#92259) The PyModuleDef_HEAD_INIT macro now uses _Py_NULL to fix C++ compiler warnings when using it in C++. --- Include/moduleobject.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Include/moduleobject.h b/Include/moduleobject.h index 8b62c45505fb61..75abd2cf2b9050 100644 --- a/Include/moduleobject.h +++ b/Include/moduleobject.h @@ -48,11 +48,11 @@ typedef struct PyModuleDef_Base { PyObject* m_copy; } PyModuleDef_Base; -#define PyModuleDef_HEAD_INIT { \ - PyObject_HEAD_INIT(NULL) \ - NULL, /* m_init */ \ - 0, /* m_index */ \ - NULL, /* m_copy */ \ +#define PyModuleDef_HEAD_INIT { \ + PyObject_HEAD_INIT(_Py_NULL) \ + _Py_NULL, /* m_init */ \ + 0, /* m_index */ \ + _Py_NULL, /* m_copy */ \ } #if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/python/cpython/commit/3a35b62ea003182c643516098cc781944d425800.patch

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy