-
-
Notifications
You must be signed in to change notification settings - Fork 34.1k
gh-144490: Fix mimalloc debug build #144620
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Does this issue exists in |
It looks like upstream fixed this earlier. The change is semantically the same: they just moved |
vstinner
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I confirm that test_cppext.TestInteralCAPI pass on Linux with Python built in debug mode.
|
Note: |
|
Sorry, @yoney and @vstinner, I could not cleanly backport this to |
|
Ah, the 3.14 branch is not affected, since the
|
|
Merged, thanks. |
Fix mimalloc C++ compilation error in debug builds.
The
_mi_assert_faildeclaration usesmi_decl_throw, which expands to__THROW(for__GNUC__). In C,__THROWis__attribute__((__nothrow__))and works anywhere. In C++,__THROWisnoexcept(true), which must come after the parameter list.Before:
After:
This fix also allows removing the
Py_DEBUGguard intest_cppext/extension.cpp, so internal C API headers are now tested in debug builds too.It’s possible this issue was introduced in #122587, though I haven’t verified it
Test:
cc: @vstinner @colesbury @DinoV