Araq / malebolgia

Malebolgia creates new spawns. Structured concurrency. Thread pools and related APIs.
MIT License
104 stars 10 forks source link

Traverse branches seperately in `checkBody` #14

Closed Gruruya closed 1 year ago

Gruruya commented 1 year ago

Without this patch, the following fails:

import malebolgia

proc a(): int = 2
var b: int

var m = createMaster()
m.awaitAll:
  if true:
    m.spawn a() -> b
  else:
    m.spawn a() -> b

The patch doesn't cover try/except