fixes anon procs created by macros
This commit is contained in:
parent
76cf4f4c1b
commit
2ad9a16e0a
2 changed files with 35 additions and 2 deletions
|
|
@ -1558,7 +1558,9 @@ proc semProcAux(c: PContext, n: PNode, kind: TSymKind,
|
|||
popOwner(c)
|
||||
if n.sons[patternPos].kind != nkEmpty:
|
||||
c.patterns.add(s)
|
||||
if isAnon: result.typ = s.typ
|
||||
if isAnon:
|
||||
n.kind = nkLambda
|
||||
result.typ = s.typ
|
||||
if isTopLevel(c) and s.kind != skIterator and
|
||||
s.typ.callConv == ccClosure:
|
||||
localError(s.info, "'.closure' calling convention for top level routines is invalid")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue