Re: [sage-devel] Comparison of Integer & numpy.int32 fails... but not always?

2011-02-17 Thread D. S. McNeil
On Wed, Feb 16, 2011 at 5:53 AM, Maxim wrote: > It would sometimes see a '1' Integer not being the same as a > '1' numpy.int32 value. > > This behaviour _cannot_ be reproduced with a minimal example such as: > > import numpy > > if numpy.int32(1) != sage.rings.integer.Integer(1): >    print("Shou

[sage-devel] Comparison of Integer & numpy.int32 fails... but not always?

2011-02-15 Thread Maxim
Hello everyone, I'd like to know if it is required practice to cast the types of the objects being compared or if Sage should be able to deal with it automatically? Because I have a problem where I need to explicitely cast an numpy.int32 vector unit for the comparison with a Sage Integer to be re