summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-05-28 01:13:49 +0200
committerAndreas Rumpf <rumpf_a@web.de>2016-05-28 01:13:49 +0200
commit64afb1039bdb2201196741434e892c1981a831b1 (patch)
tree18762492429cc59da1522911ccca6cc07071ad9a
parent51c62a211bca12cc2f470add7bf64b0f4536d6e6 (diff)
parent929865ff628322da213f2296b6dcef3f4107129f (diff)
downloadNim-64afb1039bdb2201196741434e892c1981a831b1.tar.gz
Merge pull request #4231 from tautologico/fix-4001
Fix issue #4001: invalid pragma {. hint[]: off .}
-rw-r--r--compiler/pragmas.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/pragmas.nim b/compiler/pragmas.nim
index 38d17eb62..dc09d8fc4 100644
--- a/compiler/pragmas.nim
+++ b/compiler/pragmas.nim
@@ -277,6 +277,7 @@ proc processDynLib(c: PContext, n: PNode, sym: PSym) =
 proc processNote(c: PContext, n: PNode) =
   if (n.kind == nkExprColonExpr) and (sonsLen(n) == 2) and
       (n.sons[0].kind == nkBracketExpr) and
+      (n.sons[0].sons.len == 2) and
       (n.sons[0].sons[1].kind == nkIdent) and
       (n.sons[0].sons[0].kind == nkIdent):
       #and (n.sons[1].kind == nkIdent):