summary refs log tree commit diff stats
path: root/compiler/semcall.nim
diff options
context:
space:
mode:
authorzah <zahary@gmail.com>2017-03-12 10:33:49 +0200
committerAndreas Rumpf <rumpf_a@web.de>2017-03-12 09:33:49 +0100
commit1be0022e7c6a8d168918998fd27412901432075d (patch)
tree64be855cb15ffb466098e33b526799a6aa49a9c7 /compiler/semcall.nim
parent6e358e318747ecd6bea66911d6144cb7eff9d172 (diff)
downloadNim-1be0022e7c6a8d168918998fd27412901432075d.tar.gz
Fixes #5167 and related problems (#5475)
This commit returns to a bit less strict checking of the number
of macro arguments, because some old immediate macros rely on a
behavior where even the arity of the macro is not being checked.

It may be better if such macros are just declared to use varargs[expr],
but this remains for another day.
Diffstat (limited to 'compiler/semcall.nim')
-rw-r--r--compiler/semcall.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/semcall.nim b/compiler/semcall.nim
index 98667b085..3a43c63b2 100644
--- a/compiler/semcall.nim
+++ b/compiler/semcall.nim
@@ -411,6 +411,7 @@ proc explicitGenericSym(c: PContext, n: PNode, s: PSym): PNode =
     let tm = typeRel(m, formal, arg, true)
     if tm in {isNone, isConvertible}: return nil
   var newInst = generateInstance(c, s, m.bindings, n.info)
+  newInst.typ.flags.excl tfUnresolved
   markUsed(n.info, s, c.graph.usageSym)
   styleCheckUse(n.info, s)
   result = newSymNode(newInst, n.info)