Skip to content

Typos in the Py_DEBUG macro name #122270

Description

@serhiy-storchaka

Bug report

Parser/pegen.c and Tools/peg_generator/peg_extension/peg_extension.c contain checks for wrong macro:

#if defined(PY_DEBUG)

They always false, because the correct name is Py_DEBUG, not PY_DEBUG. Therefore, the code which was supposed to run in the debug build, is never compiled code.

cc @pablogsal

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.12only security fixes3.13bugs and security fixes3.14bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)topic-parsertype-bugAn unexpected behavior, bug, or error
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions