Skip to content

[mypyc] Use PyObject_CallNoArgs and PyObject_CallOneArg instead of PyObject_CallFunctionObjArgs #12862

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
May 25, 2022

Conversation

97littleleaf11
Copy link
Collaborator

@97littleleaf11 97littleleaf11 commented May 24, 2022

Description

Use PyObject_CallNoArgs and PyObject_CallOneArg to replace PyObject_CallFunctionObjArgs in lib-rt, since the new API costs less memory according to python/cpython#13890 (comment)

Also remove the macro in pythonsupport.h since the two API are already covered by pythoncapi_compat.h.

Copy link
Collaborator

@JukkaL JukkaL left a comment

Choose a reason for hiding this comment

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

Makes sense!

@JukkaL JukkaL merged commit 405efd2 into python:master May 25, 2022
@97littleleaf11 97littleleaf11 deleted the use-call-no-args branch May 25, 2022 16:04
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