From 7ed99544e4cc1c09bd5abf9f54869c3122fa033b Mon Sep 17 00:00:00 2001 From: Jim Mussared Date: Fri, 12 Feb 2021 14:11:18 +1100 Subject: extmod/uasyncio: Add asyncio.current_task(). Matches CPython behavior. Fixes #6686 --- docs/library/uasyncio.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs') diff --git a/docs/library/uasyncio.rst b/docs/library/uasyncio.rst index a81e532d7..3316f908d 100644 --- a/docs/library/uasyncio.rst +++ b/docs/library/uasyncio.rst @@ -40,6 +40,10 @@ Core functions Returns the corresponding `Task` object. +.. function:: current_task() + + Return the `Task` object associated with the currently running task. + .. function:: run(coro) Create a new task from the given coroutine and run it until it completes. -- cgit v1.2.3