diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-09-22 20:18:13 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-22 20:18:13 +0200 |
commit | a2587aad0d327f91600fee22399c2e53e9a923cf (patch) | |
tree | b2a756263fc1d3d63a8529cc9825a378282e1245 /lib/pure | |
parent | b2b9af6a5083203d37ec3379d841ec8dc08e6674 (diff) | |
parent | 75a981cf80cb9f4cdff83a6ff525f6428b3ab5f1 (diff) | |
download | Nim-a2587aad0d327f91600fee22399c2e53e9a923cf.tar.gz |
Merge pull request #9035 from LemonBoy/fix-3075
Skip nested procedures in .async. macro
Diffstat (limited to 'lib/pure')
-rw-r--r-- | lib/pure/asyncmacro.nim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/pure/asyncmacro.nim b/lib/pure/asyncmacro.nim index 9e0893a4d..1a45fdac7 100644 --- a/lib/pure/asyncmacro.nim +++ b/lib/pure/asyncmacro.nim @@ -177,6 +177,9 @@ proc processBody(node, retFutureSym: NimNode, var newDiscard = node result.createVar("futureDiscard_" & $toStrLit(node[0][1]), node[0][1], newDiscard[0], newDiscard, node) + of RoutineNodes: + # skip all the nested procedure definitions + return else: discard for i in 0 ..< result.len: |