On 4/26/07, Guido van Rossum <[EMAIL PROTECTED]> wrote:
> - Where should PartiallyOrdered and TotallyOrdered live?
Could someone please post some sample code using either of
these? I don't see what they're good for.
Here's my failed attempt:
def my_max(a : TotallyOrdered, b : TotallyOrdered):
return a if a >= b else b
But this is both too loose (consider my_max(7, "spam"))
and too strict (consider my_max([1, 2], [2, 1])).
-j
_______________________________________________
Python-3000 mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe:
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com