summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2014-11-28 09:32:37 +0100
committerAraq <rumpf_a@web.de>2014-11-28 09:32:37 +0100
commitc45e89b486dda811ba94f4a55509d6820596be1b (patch)
tree2422839827e1e7dc6b655e98f879170031c1bcca
parent105a0616a9da7c9c85adfa488a1db42eb17daafb (diff)
downloadNim-c45e89b486dda811ba94f4a55509d6820596be1b.tar.gz
fixes #1039
-rw-r--r--compiler/semgnrc.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/semgnrc.nim b/compiler/semgnrc.nim
index 0fa16497c..723789a31 100644
--- a/compiler/semgnrc.nim
+++ b/compiler/semgnrc.nim
@@ -350,7 +350,7 @@ proc semGenericStmt(c: PContext, n: PNode,
   of nkProcDef, nkMethodDef, nkConverterDef, nkMacroDef, nkTemplateDef, 
      nkIteratorDef, nkLambdaKinds: 
     checkSonsLen(n, bodyPos + 1)
-    if n.kind notin nkLambdaKinds:
+    if n.sons[namePos].kind != nkEmpty:
       addTempDecl(c, getIdentNode(n.sons[0]), skProc)
     openScope(c)
     n.sons[genericParamsPos] = semGenericStmt(c, n.sons[genericParamsPos],