Aahz wrote: > In article <[EMAIL PROTECTED]>, > Alex Martelli <[EMAIL PROTECTED]> wrote: >> In Python 3000, ordering comparisons will not exist by default (sigh, a >> modest loss of practicality on the altar of purity -- ah well, saw it >> coming, ever since complex numbers lost ordering comparisons), but >> equality and hashing should remain just like now (yay!). > > While emotionally I agree with you, in practice I have come to agree > with the POV that allowing default ordering comparisons between disjoint > types causes subtle bugs that are more difficult to fix than the small > amount of boilerplate needed to force comparisons when desired.
I agree. It makes more sense to have to specify an ordering rather than assume an arbitrary one that may or may not have any relation to what you're interested in. I always did think that the inability to compare complex numbers was a bit of a wart -- not because it's not mathematically correct, since it is, but rather since everything else was comparable, even between distinct types -- but I think the more sensible approach is to allow equality by default (which defaults to identity), and only support comparisons when the user defines what it is he wants them to mean. -- Erik Max Francis && [EMAIL PROTECTED] && http://www.alcyone.com/max/ San Jose, CA, USA && 37 20 N 121 53 W && AIM, Y!M erikmaxfrancis Water which is too pure has no fish. -- Ts'ai Ken T'an -- http://mail.python.org/mailman/listinfo/python-list