better be safe than sorry

This commit is contained in:
Andreas Rumpf
2016-07-15 13:29:22 +02:00
parent 0834cd63d9
commit 57c52d05df

View File

@@ -1650,7 +1650,8 @@ proc semExpandToAst(c: PContext, n: PNode): PNode =
# Preserve the magic symbol in order to be handled in evals.nim
internalAssert n.sons[0].sym.magic == mExpandToAst
#n.typ = getSysSym("NimNode").typ # expandedSym.getReturnType
n.typ = sysTypeFromName"NimNode"
n.typ = if getCompilerProc("NimNode") != nil: sysTypeFromName"NimNode"
else: sysTypeFromName"PNimrodNode"
result = n
proc semExpandToAst(c: PContext, n: PNode, magicSym: PSym,