This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: make fails with gcc 4.9 due to fatal warning of unused variable and empty macro in Parser/pgen.c
Type: Stage: resolved
Components: Build Versions: Python 2.7
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: iritkatriel, krichter, meador.inge
Priority: normal Keywords: patch

Created on 2015-06-24 22:13 by krichter, last changed 2022-04-11 14:58 by admin. This issue is now closed.

File name Uploaded Description Edit
0001-removed-empty-definition-of-REQN-preprocessor-macro-.patch krichter, 2015-06-24 22:13
Messages (4)
msg245781 - (view) Author: Karl Richter (krichter) Date: 2015-06-24 22:13
`gcc` 4.9 is more restictive and recognizes that the empty definition of the `REQN` macro doesn't use some variables. It's more suitable to wrap the usage of the macro in the same preprocessor conditionals like the macro definition.

experienced with 41fbc222af8c503e1659250a36f4e293d864a92b

Patch attached. Tests pass (see for details).
msg245783 - (view) Author: Meador Inge (meador.inge) * (Python committer) Date: 2015-06-24 23:21
What is the exact GCC revision and what are the error messages?  I just tried GCC 4.9.3 and GCC 4.10.0 and don't see the errors.

Also, what configure and make parameters did you use to trigger the error?
I did './configure --with-pydebug' and './configure' with 'make -j4'.
msg245786 - (view) Author: Karl Richter (krichter) Date: 2015-06-24 23:25
It's a fatal warning of `gcc 4.9.2`, not an error (my bad) for `int i;` in `Parser/pgen.c` line 227. It might be ignored as well, but I think my approach is more elegant and deals with issues sooner than later.
msg382222 - (view) Author: Irit Katriel (iritkatriel) * (Python committer) Date: 2020-12-01 09:18
This macro is no longer in the codebase.
Date User Action Args
2022-04-11 14:58:18adminsetgithub: 68694
2020-12-01 09:18:30iritkatrielsetstatus: open -> closed

nosy: + iritkatriel
messages: + msg382222

resolution: out of date
stage: resolved
2015-06-24 23:25:28krichtersetmessages: + msg245786
2015-06-24 23:21:18meador.ingesetnosy: + meador.inge
messages: + msg245783
2015-06-24 22:13:04krichtercreate