Skip to content

Commit a3c88ef

Browse files
njsmithwillingc
authored andcommittedSep 18, 2018
Clarify that AsyncExitStack works with coroutine functions (pythonGH-9405)
The docs were ambiguous about whether you pass in a coroutine function or a coroutine object, e.g. is it: aestack.push_async_exit(some_async_func) or aestack.push_async_exit(some_async_func()) (It's the first one.)
1 parent 79d1c2e commit a3c88ef

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎Doc/library/contextlib.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -471,11 +471,11 @@ Functions and classes provided:
471471
.. method:: push_async_exit(exit)
472472

473473
Similar to :meth:`push` but expects either an asynchronous context manager
474-
or a coroutine.
474+
or a coroutine function.
475475

476476
.. method:: push_async_callback(callback, *args, **kwds)
477477

478-
Similar to :meth:`callback` but expects a coroutine.
478+
Similar to :meth:`callback` but expects a coroutine function.
479479

480480
.. method:: aclose()
481481

0 commit comments

Comments
 (0)
Please sign in to comment.