On 10/12/2017 03:44 PM, Chris Barker wrote:
I think we've drifted into a new topic, but...

I was thinking about this last spring, when I tried to cram all sorts of python 
metaprogramming into one 3hr class...

Trying to come up with a an exam[ple for metclasses, I couldn't come up with 
anything that couldn't be done more claerly
(to me) with a class decorator.

The Enum data type requires metaclasses.

Any time you want to modify the behavior of a class (not its instances, the 
class itself) you need a metaclass.

Agreed that it's pretty rare, but we need them.

--
~Ethan~

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to