You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
proccomputeValue(): Type {.async.} =let
a =?await service.getSomeValueAsync()
b =?await service.getAnotherValueAsync()
c =?someComputation(a, b)
return c
## where proc signatures areprocgetSomeValueAsync(self: Service): Future[?!SomeType]
procgetAnotherValueAsync(self: Service): Future[?!AnotherType]
procsomeComputation(a: SomeType, b: AnotherType): ?!Outcome
Currently we have to use without which is more verbose
proccomputeValue(): Type {.async.} =without a =?await service.getSomeValueAsync(), err:
returnfailure(err)
without b =?await service.getAnotherValueAsync(), err:
returnfailure(err)
without c =?someComputation(a, b), err:
returnfailure(err)
return c
The text was updated successfully, but these errors were encountered:
It would be nice to make this syntax work:
Currently we have to use
without
which is more verboseThe text was updated successfully, but these errors were encountered: