In article <[email protected]>, Martin v. Loewis <[email protected]> wrote: >Martin deleted the attribution for Carl Banks: >> >> The cmp argument doesn't depend in any way on an object's __cmp__ >> method, so getting rid of __cmp__ wasn't any good readon to also get >> rid of the cmp argument > >So what do you think about the cmp() builtin? Should have stayed, >or was it ok to remove it? > >If it should have stayed: how should it's implementation have looked like? > >If it was ok to remove it: how are people supposed to fill out the cmp= >argument in cases where they use the cmp() builtin in 2.x?
Actually, my take is that removing __cmp__ was a mistake. (I already argued about it back in python-dev before it happened, and I see little point rehashing it. My reason is strictly efficiency grounds: when comparisons are expensive -- such as Decimal object -- __cmp__ is faster.) -- Aahz ([email protected]) <*> http://www.pythoncraft.com/ "Beware of companies that claim to be like a family. They might not be lying." --Jill Lundquist -- http://mail.python.org/mailman/listinfo/python-list
