New submission from Andrés Delfino <adelf...@gmail.com>:

Since Python 3.6, when PEP 520 was accepted, class attribute definition order 
is preserved. That alone is sufficient to replace the example, but then 3.7 
came with guaranteed dictionary insertion order. The metaclass example uses 
OrderedDict, what may cause confusing to new programmers, since it is not 
needed.

I'm creating this issue in case someone who actually has used metaclasses can 
come up with an example, but I'll try to find/think of an example myself.

----------
assignee: docs@python
components: Documentation
messages: 319166
nosy: adelfino, docs@python
priority: normal
severity: normal
status: open
title: New metaclass example for Data Model topic
type: enhancement
versions: Python 3.6, Python 3.7, Python 3.8

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

Reply via email to