mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-18 10:37:12 +00:00
Merge pull request #6122 from ephja/asyncfutures-missed-rewrite
make asyncfutures.complete compile
This commit is contained in:
@@ -165,8 +165,7 @@ proc complete*[T](future: FutureVar[T], val: T) =
|
||||
assert(fut.error.isNil())
|
||||
fut.finished = true
|
||||
fut.value = val
|
||||
if not fut.cb.isNil():
|
||||
fut.cb()
|
||||
fut.callbacks.call()
|
||||
|
||||
proc fail*[T](future: Future[T], error: ref Exception) =
|
||||
## Completes ``future`` with ``error``.
|
||||
|
||||
Reference in New Issue
Block a user