diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pure/sugar.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/sugar.nim b/lib/pure/sugar.nim index 5cece12b6..cc681a0a6 100644 --- a/lib/pure/sugar.nim +++ b/lib/pure/sugar.nim @@ -242,7 +242,7 @@ macro capture*(locals: varargs[typed], body: untyped): untyped {.since: (1, 1).} error("The variable name cannot be `result`!", arg) params.add(newIdentDefs(ident(arg.strVal), freshIdentNodes getTypeInst arg)) result = newNimNode(nnkCall) - result.add(newProc(newEmptyNode(), params, body, nnkProcDef)) + result.add(newProc(newEmptyNode(), params, body, nnkLambda)) for arg in locals: result.add(arg) since (1, 1): |