Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.0-beta-5
-
None
-
None
-
Windows XP
Description
Comparisons with Integer.MAX_VALUE work correctly; comparisons with Integer.MIN_VALUE do not. Consider:
println "8 < MAX_VALUE direct: " + (8 < Integer.MAX_VALUE)
hi = Integer.MAX_VALUE
println "8 < MAX_VALUE indirect: " + (8 < hi)
println "8 > MIN_VALUE direct: " + (8 > Integer.MIN_VALUE)
hi = Integer.MIN_VALUE
println "8 > MIN_VALUE indirect: " + (8 > hi)
The output is:
8 < MAX_VALUE direct: true
8 < MAX_VALUE indirect: true
8 > MIN_VALUE direct: false
8 > MIN_VALUE indirect: false
(Note: there's nothing special about the value '8'...