[sage-devel] Re: rich comparision for elements

2009-03-28 Thread Florent Hivert
Dear Martin Raum, > Are you aware of any discussion about what should be comparable? > Otherwise I will work our something and post it to Trac. I think this > is the way to do it, isn't it? You should have a look at the huge thread about "element of integermod is element of integer?"

[sage-devel] Re: rich comparision for elements

2009-03-28 Thread Robert Bradshaw
On Mar 28, 2009, at 10:50 AM, Martin Raum wrote: > On 27 Mrz., 20:24, Robert Bradshaw > wrote: >> It would be very good to cleanup/revise the code in there, but >> beware, it is rather fragile. There has also been discussion to make >> *less* things comparable, so it should probably be done with

[sage-devel] Re: rich comparision for elements

2009-03-28 Thread Carl Witty
On Sat, Mar 28, 2009 at 10:50 AM, Martin Raum wrote: > Are you aware of any discussion about what should be comparable? > Otherwise I will work our something and post it to Trac. I think this > is the way to do it, isn't it? People have specifically complained about the complex numbers and numbe

[sage-devel] Re: rich comparision for elements

2009-03-28 Thread Martin Raum
On 27 Mrz., 20:24, Robert Bradshaw wrote: > It would be very good to cleanup/revise the code in there, but   > beware, it is rather fragile. There has also been discussion to make   > *less* things comparable, so it should probably be done with that in   > mind. > > Just curious, did you have a s

[sage-devel] Re: rich comparision for elements

2009-03-27 Thread Robert Bradshaw
On Mar 27, 2009, at 5:22 AM, Martin Raum wrote: > Hi, > > There seems to be a quite strange behaviour of _richcmp in > structure.element.pyx. If the parents need to be coerced, afterwards > left._richcmp_ is called. But if they don't, left.__cmp__ is called, > hence > assuming a totally ordered p