Add cr_await, cr_code, cr_frame and cr_running to Coroutine (#2530)

This commit is contained in:
Dave Halter
2018-10-21 13:56:52 +02:00
committed by Sebastian Rittau
parent 82d54ce57b
commit a972a8db73

View File

@@ -163,6 +163,15 @@ class Awaitable(Protocol[_T_co]):
def __await__(self) -> Generator[Any, None, _T_co]: ...
class Coroutine(Awaitable[_V_co], Generic[_T_co, _T_contra, _V_co]):
@property
def cr_await(self) -> Optional[Any]: ...
@property
def cr_code(self) -> CodeType: ...
@property
def cr_frame(self) -> FrameType: ...
@property
def cr_running(self) -> bool: ...
@abstractmethod
def send(self, value: _T_contra) -> _T_co: ...