gh-99485: Remove PyGen_New() function by vstinner · Pull Request #100075 · python/cpython · GitHub
Skip to content

gh-99485: Remove PyGen_New() function - #100075

Closed
vstinner wants to merge 1 commit into
python:mainfrom
vstinner:remove_gen_new
Closed

vstinner wants to merge 1 commit into
python:mainfrom
vstinner:remove_gen_new

Conversation

@vstinner

@vstinner vstinner commented Dec 7, 2022

Copy link
Copy Markdown
Member

Remove untested functions which were used to create generators and coroutines:

  • PyAsyncGen_New()
  • PyCoro_New()
  • PyGen_New()
  • PyGen_NewWithQualName()

In Python 3.10, make_coro() of Python/ceval.c creates generators and coroutines from a frame object. In Python 3.11, the function became _Py_MakeCoro() in Python/genobject.c and it takes a function as argument instead of a frame.

Remove untested functions which were used to create generators and
coroutines:

* PyAsyncGen_New()
* PyCoro_New()
* PyGen_New()
* PyGen_NewWithQualName()

In Python 3.10, make_coro() of Python/ceval.c creates generators and
coroutines from a frame object. In Python 3.11, the function became
_Py_MakeCoro() in Python/genobject.c and it takes a function as
argument instead of a frame.
@vstinner
vstinner requested a review from markshannon as a code owner December 7, 2022 14:17
@netlify

netlify Bot commented Dec 7, 2022

Copy link
Copy Markdown

@vstinner

vstinner commented Dec 7, 2022

Copy link
Copy Markdown
Member Author

@vstinner vstinner closed this Dec 13, 2022
@vstinner
vstinner deleted the remove_gen_new branch December 13, 2022 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants