asyncio: Fix CoroWrapper (fix my previous commit)

Add __name__ and __doc__ to __slots__
This commit is contained in:
Victor Stinner 2014-01-16 01:55:29 +01:00
parent 4d7a29c5de
commit bac7793b5b
1 changed files with 1 additions and 3 deletions

View File

@ -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