mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-22 07:15:22 +00:00
fix VM uint conversion size bug, stricter int gen on JS (#22150)
* fix VM uint conversion bug, stricter int gen on JS fixes #19929 * fix float -> uint64 conversion too * no need to mask to source type * simpler diff with explanation, add test for described issue
This commit is contained in:
@@ -75,3 +75,10 @@ macro foo2() =
|
||||
|
||||
foo()
|
||||
foo2()
|
||||
|
||||
block:
|
||||
const neg5VM = block:
|
||||
let x = -5'i8
|
||||
uint64(x)
|
||||
let y = -5'i8
|
||||
doAssert uint64(y) == neg5VM
|
||||
|
||||
Reference in New Issue
Block a user