Skip to content

fix: remove Py_single_input macro redefinition in PyMethodBase.h#21408

Merged
guitargeek merged 1 commit intoroot-project:masterfrom
chrisburr:fix/pymva-py-single-input-redefine
Feb 27, 2026
Merged

fix: remove Py_single_input macro redefinition in PyMethodBase.h#21408
guitargeek merged 1 commit intoroot-project:masterfrom
chrisburr:fix/pymva-py-single-input-redefine

Conversation

@chrisburr
Copy link
Contributor

  • Remove the #define Py_single_input 256 from the public header PyMethodBase.h to avoid a -Wmacro-redefined warning when CPython's compile.h is included after the precompiled header already defines the macro
  • Replace the Py_single_input default argument in PyRunString with the literal value 256 and a comment

Fixes conda-forge/root-feedstock#342

Remove the `#define Py_single_input 256` from the public header to
avoid a `-Wmacro-redefined` warning when CPython's compile.h is
included after the precompiled header already defines the macro.
The default argument now uses the literal value with a comment.
@chrisburr chrisburr requested a review from lmoneta as a code owner February 27, 2026 14:37
Copy link
Contributor

@guitargeek guitargeek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much!

@guitargeek guitargeek merged commit 567ae36 into root-project:master Feb 27, 2026
28 of 29 checks passed
@guitargeek
Copy link
Contributor

/backport to 6.36, 6.38

@root-project-bot
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Warning when using root_base with CPython 3.14 on osx-arm64?

3 participants