* fixes #15130 * you really have to copy from cursors
This commit is contained in:
parent
9ff2c50155
commit
8e3f51f06c
3 changed files with 81 additions and 4 deletions
|
|
@ -628,7 +628,7 @@ proc isAnalysableFieldAccess*(orig: PNode; owner: PSym): bool =
|
|||
# XXX Allow closure deref operations here if we know
|
||||
# the owner controlled the closure allocation?
|
||||
result = n.kind == nkSym and n.sym.owner == owner and
|
||||
sfGlobal notin n.sym.flags and
|
||||
{sfGlobal, sfThread, sfCursor} * n.sym.flags == {} and
|
||||
(n.sym.kind != skParam or isSinkParam(n.sym)) # or n.sym.typ.kind == tyVar)
|
||||
# Note: There is a different move analyzer possible that checks for
|
||||
# consume(param.key); param.key = newValue for all paths. Then code like
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue