[Python-Dev] subclasses() return order (original) (raw)

Nick Coghlan ncoghlan at gmail.com
Sun May 26 06:36:28 CEST 2013


On Sat, May 25, 2013 at 11:49 PM, Ɓukasz Langa <lukasz at langa.pl> wrote:

I guess I should explain myself more clearly: subclasses() already computes its result on-the-fly (it must weed out dead weakrefs) (*). So the visible behaviour of subclasses wouldn't change, except for ordering.

+1 Makes sense to me. As currently defined, you cannot rely on the item order anyway.

Another concurrence here - if any code in the world depends on subclasses always returning entries in the exact order they happen to be returned in right now, I'm quite happy to declare that code implementation dependent and thus exempt from the normal backwards compatibility guarantees :)

Cheers, Nick.



More information about the Python-Dev mailing list