New submission from Keith <keithtan...@gmail.com>:

The Python library will not compile with a C++2020 compiler because the code 
uses the reserved “module” keyword
 
For example, in warnings.h, we have the following code:
 
#ifndef Py_LIMITED_API
PyAPI_FUNC(int) PyErr_WarnExplicitObject(
    PyObject *category,
    PyObject *message,
    PyObject *filename,
    int lineno,
    PyObject *module,
PyObject *registry);
 
 
In modsupport.h we have the following code:
PyAPI_FUNC(int) PyModule_ExecDef(PyObject *module, PyModuleDef *def);
 
We can fix this by using a different identifier, for example “pyModule” instead 
of “module”

----------
components: C API
messages: 360103
nosy: aCuria
priority: normal
severity: normal
status: open
title: The Python library will not compile with a C++2020 compiler because the 
code uses the reserved “module” keyword
versions: Python 2.7, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue39355>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to