What version will contain dataclasses?
>>> class MyClass(namedtuple('_MyClass', ['x', 'y', 'z'])):
... def foo(self):
... return self.x * self.y + self.z
...
>>> x = MyClass(4, 5, 6)
>>> x.foo()
26
... or an attrs decorated class with frozen=True? >>> import attr
>>> @attr.s(frozen=True)
... class MyClass:
... x = attr.ib()
... y = attr.ib()
... z = attr.ib()
... def foo(self):
... return self.x * self.y + self.z
...
>>> x = MyClass(4, 5, 6)
>>> x.foo()
26see: https://github.com/ericvsmith/dataclasses
and this comment thread is revealing: https://github.com/ericvsmith/dataclasses/issues/19