Eric V. Smith <e...@trueblade.com> added the comment:

Hmm. That's a regression, at least from 3.7, which is the only version I have 
ready access to:

$ python3
Python 3.7.3 (default, Mar 27 2019, 13:36:35) 
[GCC 9.0.1 20190227 (Red Hat 9.0.1-0.8)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import dataclasses
>>> @dataclasses.dataclass
... class X:
...   a: int
...   b:int
... 
>>> X.__doc__
'X(a: int, b: int)'
>>> 

$ python3
Python 3.7.3 (default, Mar 27 2019, 13:36:35) 
[GCC 9.0.1 20190227 (Red Hat 9.0.1-0.8)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from __future__ import annotations
>>> import dataclasses
>>> @dataclasses.dataclass
... class X:
...   a: int
...   b:int
... 
>>> X.__doc__
"X(a: 'int', b: 'int')"

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue40794>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to