Message9133

Author jeff.allen
Recipients jeff.allen, santa4nt, zyasoft
Date 2014-10-13.08:23:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1413188623.8.0.769832466923.issue2216@psf.upfronthosting.co.za>
In-reply-to
Content
This is apparently in response to http://permalink.gmane.org/gmane.comp.lang.jython.user/10467, but I think it does not answer the underlying problem. The underlying problem is a bug in our JSR-223 implementation probably also identified in #2090 and #1494. The mistake is to test this at the REPL prompt, when the problem is in the *different* interpreter used by the script engine. This seems to be why #1494 was closed, in error I think.

You could say the observed behaviour is correct, under the arcane Python 2 rules. BigInteger is not a special Java class to the interpreter, so it is not numerically comparable to int. Alternatively, having Jython treat java.lang.BigInteger as a number *may* be a good idea. (How about BigDecimal too? Or java.lang.Number in general, in the same way that Comparable gets special treatment?) It would be a new feature, not a bug-fix.
History
Date User Action Args
2014-10-13 08:23:43jeff.allensetmessageid: <1413188623.8.0.769832466923.issue2216@psf.upfronthosting.co.za>
2014-10-13 08:23:43jeff.allensetrecipients: + jeff.allen, zyasoft, santa4nt
2014-10-13 08:23:43jeff.allenlinkissue2216 messages
2014-10-13 08:23:42jeff.allencreate