[issue33880] namedtuple should use NFKD to find duplicate members
Eric V. Smith
report at bugs.python.org
Sat Jun 16 13:59:31 EDT 2018
Eric V. Smith <eric at trueblade.com> added the comment:
Not that it really matters to this issue, but here's how dataclasses and attrs deal with this:
dataclasses has the same issue, via make_dataclass().
attrs gives a syntax error with your field names, but interestingly this succeeds:
>>> Foo = attr,make_class('Foo', ['a', 'b', 'a'])
>>> Foo(1, 3)
I'll open a corresponding issue for dataclasses.
Foo(a=1, b=3)
----------
nosy: +eric.smith
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33880>
_______________________________________
More information about the Python-bugs-list
mailing list