[Python-Dev] cmp(x,x) (original) (raw)
Gustavo Niemeyer niemeyer at conectiva.com
Tue May 18 13🔞43 EDT 2004
- Previous message: [Python-Dev] cmp(x,x)
- Next message: [Python-Dev] cmp(x,x)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
>>> cmp(x,x) # x.cmp() is NOT called 0
This is odd. We'll have problems trying to implemnt a NaN following the convention of being not-equal to itself, for example.
>>> [x] == [x] # x.cmp() is NOT called True
This is correct, IMO.
-- Gustavo Niemeyer http://niemeyer.net
- Previous message: [Python-Dev] cmp(x,x)
- Next message: [Python-Dev] cmp(x,x)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]