Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-132775: Expand the Capability of Interpreter.call()#133484

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
ericsnowcurrently wants to merge4 commits intopython:main
base:main
Choose a base branch
Loading
fromericsnowcurrently:interp-call-expansion

Conversation

ericsnowcurrently
Copy link
Member

@ericsnowcurrentlyericsnowcurrently commentedMay 6, 2025
edited
Loading

It now supports most callables, full args, and return values.

Comment on lines +235 to 238
def call(self, callable, /, *args, **kwargs):
"""Call the object in the interpreter with given args/kwargs.

Only functions that take no arguments and have no closure
Copy link
Contributor

@neoneneneoneneMay 13, 2025
edited
Loading

Choose a reason for hiding this comment

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

The docstring looks partially outdated (here or inLib/interpreters/__init__.py). The same would apply for_interpretersmodule.c?

PyDoc_STRVAR(exec_doc,...- The code/function must not take any arguments or be a closure (i.e. have cell vars).+ The code/function must not take any arguments.PyDoc_STRVAR(run_func_doc,...- In both cases, closures and args are not supported.

@ericsnowcurrentlyericsnowcurrentlyforce-pushed theinterp-call-expansion branch 4 times, most recently fromd58f54e to4152f17CompareMay 22, 2025 15:16
@ericsnowcurrentlyericsnowcurrently marked this pull request as ready for reviewMay 22, 2025 16:34
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@neoneneneoneneneonene left review comments

Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@ericsnowcurrently@neonene

[8]ページ先頭

©2009-2025 Movatter.jp