[Python-3000] Total ordering and __cmp__
tjreedy at udel.edu
Thu Mar 22 02:43:07 CET 2007
Terry Reedy schrieb:
| > In any case, this point is that dict ordering is as arbitrary as
| > for instance, a dict and a string. Since Guido stopped the experiment
| > totally ordering all objects when complex nums were added, consistency
| > suggests that all fake orderings be eliminated, leaving only the order
| > numbers, characters, and sequences of comparable objects.
I should have added that not having an arbitrary total order allows for
useful partial orders. The comparisons on sets appear to be such now
(based on inclusion) and RH mentioned doing the same for dicts in 3.0.
More information about the Python-3000