summary refs log tree commit diff stats
path: root/compiler/semexprs.nim
diff options
context:
space:
mode:
authorZahary Karadjov <zahary@gmail.com>2014-03-09 21:04:12 +0200
committerZahary Karadjov <zahary@gmail.com>2014-03-09 21:04:12 +0200
commit29b7104a5330ebcb188243a271b4409e8613837b (patch)
tree2664c6c0f6553fc96cb7ca17a2d0dd6edba13540 /compiler/semexprs.nim
parent752352a6834dad94e0687b2518240e8425e6bcac (diff)
downloadNim-29b7104a5330ebcb188243a271b4409e8613837b.tar.gz
fix #829; (macros.quote)
the fix is a little bit peculiar:

the inserted call to getAst was getting a false-positive for being a lambda proc,
because lambdalifting.isInnerProc takes into account who is the owner of a given
symbol: (a nested proc is a callable symbol owned by the enclosing proc)
Diffstat (limited to 'compiler/semexprs.nim')
-rw-r--r--compiler/semexprs.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim
index d07d695da..77ac98db7 100644
--- a/compiler/semexprs.nim
+++ b/compiler/semexprs.nim
@@ -1358,7 +1358,7 @@ proc expectString(c: PContext, n: PNode): string =
     localError(n.info, errStringLiteralExpected)
 
 proc getMagicSym(magic: TMagic): PSym =
-  result = newSym(skProc, getIdent($magic), getCurrOwner(), gCodegenLineInfo)
+  result = newSym(skProc, getIdent($magic), systemModule, gCodegenLineInfo)
   result.magic = magic
 
 proc newAnonSym(kind: TSymKind, info: TLineInfo,