Files
Nim/tests/errmsgs/tconstinfo.nim
metagn 5684093135 fix for bad error message with const in case statement (#21182)
* preliminary fix for bad error message with const

* add test case

* fix tmatrixconcept and tmatrixlib
2022-12-27 21:24:00 +01:00

8 lines
172 B
Nim

# https://forum.nim-lang.org/t/9762
const foo = "abc"
case 'a'
of foo: echo "should error" #[tt.Error
^ type mismatch: got <string> but expected 'char']#
else: discard