From eee99ab2725562195e7324cf8ccc521a15a0611e Mon Sep 17 00:00:00 2001 From: Araq Date: Wed, 11 Jul 2012 18:27:14 +0200 Subject: fixes #112 --- compiler/parser.nim | 2 ++ 1 file changed, 2 insertions(+) (limited to 'compiler/parser.nim') diff --git a/compiler/parser.nim b/compiler/parser.nim index 194b61f2a..e65503b2c 100755 --- a/compiler/parser.nim +++ b/compiler/parser.nim @@ -1247,6 +1247,8 @@ proc parseEnum(p: var TParser): PNode = getTok(p) optInd(p, a) addSon(result, a) + if result.len <= 1: + lexMessage(p.lex, errIdentifierExpected, prettyTok(p.tok)) proc parseObjectPart(p: var TParser): PNode proc parseObjectWhen(p: var TParser): PNode = -- cgit 1.4.1-2-gfad0