Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.8.1
-
None
Description
I would expect that range literal follow the same type promotion rules as arithmetic operations, yet:
assert (1+10).class == Integer assert (1L+10).class == Long assert (1+10L).class == Long assert (1..10).every { it.class == Integer } assert (1L..10).every { it.class == Long } assert (1..10L).every { it.class == Integer } // <= weird