GDScript: Fix MIN_INT not representable as numeric literal
This commit is contained in:
parent
d2b1474da7
commit
d15511725a
4 changed files with 66 additions and 0 deletions
|
|
@ -0,0 +1,17 @@
|
|||
func test():
|
||||
print(-9223372036854775808 == (1 << 63))
|
||||
print(-2)
|
||||
print(- 2)
|
||||
print(---2)
|
||||
print(3 - 2)
|
||||
print(3-2)
|
||||
print(3---2)
|
||||
print(-3 - 2)
|
||||
print(-3 - -2)
|
||||
print(-(3 - 2)-2)
|
||||
print([1, 2, 3][0]-1)
|
||||
var t = 1
|
||||
print(t-1)
|
||||
print(-0xFF)
|
||||
print(1--0xFF)
|
||||
print(floor(PI-1))
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
GDTEST_OK
|
||||
true
|
||||
-2
|
||||
-2
|
||||
-2
|
||||
1
|
||||
1
|
||||
1
|
||||
-5
|
||||
-1
|
||||
-3
|
||||
0
|
||||
0
|
||||
-255
|
||||
256
|
||||
2
|
||||
Loading…
Add table
Add a link
Reference in a new issue