fixes #3066
This commit is contained in:
parent
f934c92132
commit
799e0f3274
2 changed files with 20 additions and 0 deletions
|
|
@ -1184,6 +1184,9 @@ proc checkCanEval(c: PCtx; n: PNode) =
|
|||
if s.kind in {skVar, skTemp, skLet, skParam, skResult} and
|
||||
not s.isOwnedBy(c.prc.sym) and s.owner != c.module:
|
||||
cannotEval(n)
|
||||
elif s.kind in {skProc, skConverter, skMethod,
|
||||
skIterator, skClosureIterator} and sfForward in s.flags:
|
||||
cannotEval(n)
|
||||
|
||||
proc isTemp(c: PCtx; dest: TDest): bool =
|
||||
result = dest >= 0 and c.prc.slots[dest].kind >= slotTempUnknown
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue