跳转到主要内容

Coroutine Objects

3.5

Coroutine objects are what functions declared with an async keyword return.

The C structure used for coroutine objects.

The type object corresponding to coroutine objects.

Return true if ob's type is PyCoro_Type; ob must not be NULL. This function always succeeds.

Create and return a new coroutine object based on the frame object, with __name__ and __qualname__ set to name and qualname. A reference to frame is stolen by this function. The frame argument must not be NULL.

3.16 3.18

This function has not been used since 3.10. It is also impossible to construct a proper frame object to call this function.