require errormsg to be specified before file.

This commit is contained in:
Arne Döring 2018-11-29 16:07:51 +01:00 • committed by Araq
commit 1105d03644
264 changed files with 305 additions and 623 deletions

View file

@ -1,13 +1,17 @@
discard """
errormsg: "type mismatch: got <string> but expected 'int'"
line: 33
file: "tcaseexpr1.nim"
line: 29
errormsg: "type mismatch: got <string> but expected 'int'"
line: 23
errormsg: "not all cases are covered"
line: 27
file: "tcaseexpr1.nim"
"""
# NOTE: This spec is wrong. Spec doesn't support multiple error
# messages. The first one is simply overridden by the second one.
# This just has never been noticed.
type
E = enum A, B, C
@ -27,4 +31,3 @@ var t1 = case x:
var t2 = case x:
of A: 10
of B, C: "23"