From bdb2d21f276c10aee122218384e568ef843690fa Mon Sep 17 00:00:00 2001 From: Araq Date: Tue, 6 May 2014 21:03:05 +0200 Subject: [PATCH] bugfix: bool for case statements --- compiler/semstmts.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/semstmts.nim b/compiler/semstmts.nim index fc4704b5ce..c2827905c3 100644 --- a/compiler/semstmts.nim +++ b/compiler/semstmts.nim @@ -190,7 +190,7 @@ proc semCase(c: PContext, n: PNode): PNode = var typ = commonTypeBegin var hasElse = false case skipTypes(n.sons[0].typ, abstractVarRange-{tyTypeDesc}).kind - of tyInt..tyInt64, tyChar, tyEnum, tyUInt..tyUInt32: + of tyInt..tyInt64, tyChar, tyEnum, tyUInt..tyUInt32, tyBool: chckCovered = true of tyFloat..tyFloat128, tyString, tyError: discard