Issue1303

classification
Title: [2.5b3] Integer.toString(long) fails with array index out of bounds
Type: behaviour Severity: normal
Components: Core Versions: 2.5b1
Milestone:
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: cassiel, fwierzbicki
Priority: low Keywords:

Created on 2009-04-04.20:29:55 by cassiel, last changed 2013-02-19.21:28:35 by fwierzbicki.

Messages
msg4439 (view) Author: Nick Rothwell (cassiel) Date: 2009-04-04.20:30:06
>>> from java.lang import Integer
>>> Integer.toString(0xFFFFFFFF)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
        at
org.python.core.PyReflectedFunction.throwBadArgError(PyReflectedFunction.java:279)
        at
org.python.core.PyReflectedFunction.throwError(PyReflectedFunction.java:300)

java.lang.ArrayIndexOutOfBoundsException:
java.lang.ArrayIndexOutOfBoundsException: 0
msg4461 (view) Author: Frank Wierzbicki (fwierzbicki) Date: 2009-04-07.00:57:14
Although you can trick Java into printing -1 with

Integer.toString(0xFFFFFFFF)

In general passing a long to this method won't even compile.  We could
try to produce a better error message though... so I'm leaving this open
but marking it as "low"
History
Date User Action Args
2013-02-19 21:28:35fwierzbickisetstatus: open -> closed
resolution: out of date
2009-04-07 00:57:17fwierzbickisetpriority: low
nosy: + fwierzbicki
messages: + msg4461
2009-04-04 20:30:07cassielsetmessages: + msg4439
2009-04-04 20:29:55cassielcreate