INADA Naoki added the comment:

When subclassing, current __repr__ uses `self.__class__.__name__`.  So you get 
meaningful name already.

When automatic generation, I recommend you to use some wrapper to cache same 
namedtuple, since creating namedtuple on the fly is costly job.

I'm afraid "unnnamed" namedtuple may lead people to use namedtuple on the fly, 
like lambda.

----------
nosy: +inada.naoki

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

Reply via email to