bpo-32311: Implement asyncio.create_task() shortcut (#4848)

* Implement functionality
* Add documentation
This commit is contained in:
Andrew Svetlov 2017-12-15 07:04:38 +02:00 committed by GitHub
parent 19a44f63c7
commit f74ef458ab
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 201 additions and 95 deletions

View file

@ -3,7 +3,7 @@ __all__ = ()
import concurrent.futures._base
import reprlib
from . import events
from . import format_helpers
Error = concurrent.futures._base.Error
CancelledError = concurrent.futures.CancelledError
@ -38,7 +38,7 @@ def _format_callbacks(cb):
cb = ''
def format_cb(callback):
return events._format_callback_source(callback, ())
return format_helpers._format_callback_source(callback, ())
if size == 1:
cb = format_cb(cb[0])