Title: python type 'long' doesn't work well under JSR 223
Type: Severity: normal
Components: Core Versions: 2.5.1
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: nriley Nosy List: akong, bupjae, nriley, pjenvey, zyasoft
Priority: Keywords:

Created on 2009-10-25.05:03:01 by bupjae, last changed 2014-10-13.15:00:11 by zyasoft.

msg5263 (view) Author: Bupjae Lee (bupjae) Date: 2009-10-25.05:03:00
C:\Program Files\Java\jdk1.6.0_16\bin>jrunscript -cp c:\jython2.5.1
\jython.jar -l jython
python> a=10L
python> print a-1
script error: TypeError: unsupported operand type(s) for -
: 'java.math.BigInteger' and 'int' in <STDIN> at line number 1

Python 'long' type is converted to java 'java.math.BigInteger' type 
unintentionally under JSR 223.

This doesn't happen when I don't use JSR 223.
msg5630 (view) Author: Philip Jenvey (pjenvey) Date: 2010-04-04.18:47:02
Over to Nick just because it's JSR 223 related
msg5789 (view) Author: Anthony Kong (akong) Date: 2010-06-01.06:25:11
Seems like it is running fine in the trunk version 

Jython 2.5.1+ (trunk, Jun 1 2010, 13:52:47)
[Java HotSpot(TM) Client VM (Sun Microsystems Inc.)] on java1.6.0_14
Type "help", "copyright", "credits" or "license" for more information.
>>> a = 10L
>>> print a-1

It is also OK in the 2.5.1rc3
msg5907 (view) Author: Jim Baker (zyasoft) Date: 2010-07-19.22:58:42
Closed per discussion on #jython
msg9134 (view) Author: Jim Baker (zyasoft) Date: 2014-10-13.15:00:11
It's been too long since this was closed to recall what the discussion on #jython was (unfortunately not copied here, and not going to try to lookup), but this is still an issue. Now tracked in #2216
Date User Action Args
2014-10-13 15:00:11zyasoftsetmessages: + msg9134
2010-07-19 22:58:42zyasoftsetstatus: open -> closed
nosy: + zyasoft
messages: + msg5907
2010-06-01 06:25:13akongsetnosy: + akong
messages: + msg5789
2010-04-04 18:47:02pjenveysetassignee: nriley
messages: + msg5630
nosy: + pjenvey
2010-04-04 18:30:34pjenveysetnosy: + nriley
2009-10-25 05:03:01bupjaecreate