Cannot parse Integer.MIN_VALUE
------------------------------

                 Key: JEXL-112
                 URL: https://issues.apache.org/jira/browse/JEXL-112
             Project: Commons JEXL
          Issue Type: Bug
    Affects Versions: 2.0.1
            Reporter: Sebb


Cannot parse Integer.MIN_VALUE, because parsing does not take account of the 
sign.

Sample code to show the error:

{code}
JEXL = new JexlEngine();
JEXL.createScript(Integer.toString(Integer.MAX_VALUE)); // OK
JEXL.createScript(Integer.toString(Integer.MIN_VALUE+1)); // OK
JEXL.createScript(Integer.toString(Integer.MIN_VALUE)); // FAILS with 
java.lang.NumberFormatException: For input string: "2147483648"
{code}

Note that the input does not include the minus sign, which is presumably going 
to be applied later.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to