* add test for #3907

(cherry picked from commit 137d608d7d)
This commit is contained in:
Bung
2023-08-06 15:21:24 +08:00
committed by narimiran
parent 36b339bbcf
commit 42e4190e1a

10
tests/misc/t3907.nim Normal file
View File

@@ -0,0 +1,10 @@
import std/assertions
let a = 0
let b = if false: -1 else: a
doAssert b == 0
let c: range[0..high(int)] = 0
let d = if false: -1 else: c
doAssert d == 0