got together

This commit is contained in:
Jaremy Creechley 2024-02-13 22:59:18 -07:00
parent bcaeda748f
commit e86a7f6727
No known key found for this signature in database
GPG Key ID: 4E66FB67B21D3300

View File

@ -11,14 +11,13 @@ import apatheia/tasks
## todo: setup basic async + threadsignal + taskpools example here
##
proc addNums(a, b: float): float {.asyncTask.} =
os.sleep(500)
os.sleep(100)
echo "adding: ", a, " + ", b
return a + b
proc addNumValues(vals: openArray[float]): float {.asyncTask.} =
os.sleep(500)
os.sleep(100)
result = 0.0
for x in vals:
result += x