Skip to content

[mypyc] Fix seg fault due to heap type objects with static tp_doc #19636

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

Merged
merged 1 commit into from
Aug 10, 2025

Conversation

brianschubert
Copy link
Member

@brianschubert brianschubert commented Aug 10, 2025

See #19634 (comment)

Is there a good way to test that this that this doesn't seg fault when we exit with an uncaught exception?

Also took the opportunity to add PyDoc_STR to the static docstrings. AFAIK this isn't strictly necessary, but it's better style and in theory makes it possible to compile without docstrings if someone wanted to do that.

Copy link
Member

@ilevkivskyi ilevkivskyi left a comment

Choose a reason for hiding this comment

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

I think there is no way to test for specific error code. Just fixing is good for now.

@ilevkivskyi ilevkivskyi merged commit 94eb6b7 into python:master Aug 10, 2025
13 checks passed
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.

2 participants