A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2017-October/149825.html below:

[Python-Dev] PEP 557: Data Classes

[Python-Dev] PEP 557: Data Classes [Python-Dev] PEP 557: Data ClassesEthan Furman ethan at stoneleaf.us
Thu Oct 12 20:56:41 EDT 2017
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~

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4