bpo-40750: Do not expand the new parser debug flags if Py_BUILD_CORE is not defined (GH-20393)

This commit is contained in:
Pablo Galindo 2020-05-25 20:17:12 +01:00 committed by GitHub
parent 800a35c623
commit deb4355a37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -1,7 +1,7 @@
// @generated by pegen.py from ./Grammar/python.gram
#include "pegen.h"
#ifdef Py_DEBUG
#if defined(Py_DEBUG) && defined(Py_BUILD_CORE)
extern int Py_DebugFlag;
#define D(x) if (Py_DebugFlag) x;
#else

View File

@ -29,7 +29,7 @@ from pegen.parser_generator import ParserGenerator
EXTENSION_PREFIX = """\
#include "pegen.h"
#ifdef Py_DEBUG
#if defined(Py_DEBUG) && defined(Py_BUILD_CORE)
extern int Py_DebugFlag;
#define D(x) if (Py_DebugFlag) x;
#else