mirror of
https://github.com/nim-lang/Nim.git
synced 2026-06-04 10:54:42 +00:00
* add test for #3907
(cherry picked from commit 137d608d7d)
This commit is contained in:
10
tests/misc/t3907.nim
Normal file
10
tests/misc/t3907.nim
Normal 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
|
||||
Reference in New Issue
Block a user