From bac7793b5b9145b350d7e7bad1c3af99a10103b7 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Thu, 16 Jan 2014 01:55:29 +0100 Subject: asyncio: Fix CoroWrapper (fix my previous commit) Add __name__ and __doc__ to __slots__ --- Lib/asyncio/tasks.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Lib/asyncio/tasks.py b/Lib/asyncio/tasks.py index 3640468..ec04d2f 100644 --- a/Lib/asyncio/tasks.py +++ b/Lib/asyncio/tasks.py @@ -32,9 +32,7 @@ _DEBUG = False class CoroWrapper: - """Wrapper for coroutine in _DEBUG mode.""" - - __slots__ = ['gen', 'func'] + __slots__ = ['gen', 'func', '__name__', '__doc__'] def __init__(self, gen, func): assert inspect.isgenerator(gen), gen -- cgit v0.12