#23919: Cleanups for when we drop Python 2 compatibility
-------------------------------------+-------------------------------------
Reporter: Tim Graham | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: Core (Other) | Version:
Severity: Normal | Resolution:
Keywords: | Triage Stage:
| Someday/Maybe
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Josh Smeaton):
Replying to [comment:4 Anssi Kääriäinen]:
> I believe we can get rid of the Field.creation_counter hack. In Python 3
it is possible to store the attrs in a sorted dictionary. See
http://stackoverflow.com/questions/4459531/how-to-read-class-attributes-
in-the-same-order-as-declared.
We could also remove this when we support python 3.6, as class attributes
retain their order. I'm guessing this is a consequence (or the cause of)
dictionaries retaining insertion order.
https://docs.python.org/3.6/whatsnew/3.6.html#pep-520-preserving-class-
attribute-definition-order
--
Ticket URL: <https://code.djangoproject.com/ticket/23919#comment:32>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/067.0c6f4467b00690c079aaf36eed5cfd9b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.