Issue #26634: recursive_repr() now sets __qualname__ of wrapper.

Patch by Xiang Zhang.
This commit is contained in:
Serhiy Storchaka 2016-04-26 09:30:44 +03:00
parent a7c0ff2f0b
commit b3b366d803
3 changed files with 18 additions and 0 deletions

View file

@ -30,6 +30,7 @@ def recursive_repr(fillvalue='...'):
wrapper.__module__ = getattr(user_function, '__module__')
wrapper.__doc__ = getattr(user_function, '__doc__')
wrapper.__name__ = getattr(user_function, '__name__')
wrapper.__qualname__ = getattr(user_function, '__qualname__')
wrapper.__annotations__ = getattr(user_function, '__annotations__', {})
return wrapper