From f0f0062a5d37614b552c4ecc40ba2a189b00b008 Mon Sep 17 00:00:00 2001 From: Dominik Picheta Date: Thu, 23 Apr 2015 00:29:16 +0100 Subject: Add sfGenSym for (_). --- compiler/semstmts.nim | 2 ++ 1 file changed, 2 insertions(+) (limited to 'compiler') diff --git a/compiler/semstmts.nim b/compiler/semstmts.nim index 24c135767..c0c48782e 100644 --- a/compiler/semstmts.nim +++ b/compiler/semstmts.nim @@ -442,6 +442,8 @@ proc semVarOrLet(c: PContext, n: PNode, symkind: TSymKind): PNode = var v = semIdentDef(c, a.sons[j], symkind) if sfGenSym notin v.flags and not isDiscardUnderscore(a.sons[j]): addInterfaceDecl(c, v) + if isDiscardUnderscore(a.sons[j]): + v.flags.incl(sfGenSym) when oKeepVariableNames: if c.inUnrolledContext > 0: v.flags.incl(sfShadowed) else: -- cgit 1.4.1-2-gfad0