recursive modules are only detected to improve error messages

This commit is contained in:
Andreas Rumpf 2016-11-24 12:27:21 +01:00
commit 01ae0d28d4
12 changed files with 57 additions and 23 deletions

View file

@ -1551,7 +1551,7 @@ proc expectMacroOrTemplateCall(c: PContext, n: PNode): PSym =
if isCallExpr(n):
var expandedSym = qualifiedLookUp(c, n[0], {checkUndeclared})
if expandedSym == nil:
localError(n.info, errUndeclaredIdentifier, n[0].renderTree)
errorUndeclaredIdentifier(c, n.info, n[0].renderTree)
return errorSym(c, n[0])
if expandedSym.kind notin {skMacro, skTemplate}: