This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eric.smith
Recipients eric.smith
Date 2017-12-26.18:34:08
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1514313248.8.0.213398074469.issue32428@psf.upfronthosting.co.za>
In-reply-to
Content
For this class:

@dataclass
class C:
   x: int = 0
   y = 0

Generate a TypeError. 'y' is not a field (as defined by @dataclass). It should either be a regular field (by giving it a type annotation) or a ClassVar field.
History
Date User Action Args
2017-12-26 18:34:08eric.smithsetrecipients: + eric.smith
2017-12-26 18:34:08eric.smithsetmessageid: <1514313248.8.0.213398074469.issue32428@psf.upfronthosting.co.za>
2017-12-26 18:34:08eric.smithlinkissue32428 messages
2017-12-26 18:34:08eric.smithcreate