You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
procfoo() =iteratorit() {.closure.} =discardprocuseIter() {.nimcall.} =var iii = it # <-- illegal captureuseIter()
foo()
nim c test
.../test.nim(5, 15) Error: illegal capture 'it' because 'useIter' has the calling convention: <nimcall>
This capture should be legal as it is a fresh local instance of the iterator.
nim --version
Nim Compiler Version 1.7.1 [Linux: amd64]
Compiled at 2022-08-03
Copyright (c) 2006-2022 by Andreas Rumpf
git hash: 0d734d7966644018207a20cf23f16912f9c276d8
active boot switches: -d:release