mark symbols in getAst context as used
This commit is contained in:
parent
ca673ab1af
commit
2d0ee2c8ab
1 changed files with 5 additions and 1 deletions
|
|
@ -1623,7 +1623,11 @@ proc semExpandToAst(c: PContext, n: PNode): PNode =
|
||||||
elif cands >= 2:
|
elif cands >= 2:
|
||||||
localError(n.info, "ambiguous symbol in 'getAst' context: " & $macroCall)
|
localError(n.info, "ambiguous symbol in 'getAst' context: " & $macroCall)
|
||||||
else:
|
else:
|
||||||
macroCall.sons[0] = newSymNode(cand)
|
let info = macroCall.sons[0].info
|
||||||
|
macroCall.sons[0] = newSymNode(cand, info)
|
||||||
|
markUsed(info, cand, c.graph.usageSym)
|
||||||
|
styleCheckUse(info, cand)
|
||||||
|
|
||||||
# we just perform overloading resolution here:
|
# we just perform overloading resolution here:
|
||||||
#n.sons[1] = semOverloadedCall(c, macroCall, macroCall, {skTemplate, skMacro})
|
#n.sons[1] = semOverloadedCall(c, macroCall, macroCall, {skTemplate, skMacro})
|
||||||
else:
|
else:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue