Message11986
We should definitely fix it. It is invalid behavior, can cause arbitrary issues, unforeseeable damage, etc. It must be fixed.
That said, an easy fix should be to replace
number = Integer.toString(-value);
by
number = Long.toString(-((long) value));
This impacts performance of non-edge-case calls. I don't think that format_d is a performance critical function, but - for what it's worth -
we can do it like
number = value == Integer.MIN_VALUE ? "2147483648" : Integer.toString(-value); |
|
Date |
User |
Action |
Args |
2018-05-16 19:17:06 | stefan.richthofer | set | messageid: <1526498226.92.0.682650639539.issue2672@psf.upfronthosting.co.za> |
2018-05-16 19:17:06 | stefan.richthofer | set | recipients:
+ stefan.richthofer, jeff.allen, jamesmudd |
2018-05-16 19:17:06 | stefan.richthofer | link | issue2672 messages |
2018-05-16 19:17:06 | stefan.richthofer | create | |
|