diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2021-05-08 16:47:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-08 16:47:06 +0200 |
commit | c14427dbf38ffe573c838a452b9187c44d063145 (patch) | |
tree | 38a0b4f1d87984ab8ca9ff9151bb017b550c5b17 /compiler | |
parent | 38b41f893a8ca21ad5ed2198866c7d6718d197fc (diff) | |
download | Nim-c14427dbf38ffe573c838a452b9187c44d063145.tar.gz |
ORC: cursor inference bugfix (#17973)
* fixed a .cursor inference bug * added a test case
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/varpartitions.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/varpartitions.nim b/compiler/varpartitions.nim index 7bb626c0a..810ce8586 100644 --- a/compiler/varpartitions.nim +++ b/compiler/varpartitions.nim @@ -695,7 +695,7 @@ proc traverse(c: var Partitions; n: PNode) = # 'paramType[0]' is still a view type, this is not a typo! if directViewType(paramType[0]) == noView and classifyViewType(paramType[0]) != noView: borrowingCall(c, paramType[0], n, i) - elif borrowChecking in c.goals and m == mNone: + elif m == mNone: potentialMutationViaArg(c, n[i], parameters) of nkAddr, nkHiddenAddr: @@ -921,4 +921,4 @@ proc computeCursors*(s: PSym; n: PNode; g: ModuleGraph) = discard "cannot cursor into a graph that is mutated" else: v.sym.flags.incl sfCursor - #echo "this is now a cursor ", v.sym, " ", par.s[rid].flags, " ", config $ v.sym.info + #echo "this is now a cursor ", v.sym, " ", par.s[rid].flags, " ", g.config $ v.sym.info |