Pudu programming language
Menu
API reference

Std.Concurrent.Scope.all

1 declaration

fn

all: &Std.Concurrent.Cancel.Token -> &Array[fn(Std.Concurrent.Cancel.Token) -> Result[T, E]] -> Result[Array[T], Std.Concurrent.Scope.ScopeError[E]]

Run every action on its own thread with one child token of parent, and answer every value in input order, or the first failure seen.

The first failure cancels the shared token. The answer comes only after every started action has finished, so no thread outlives the call.

Back to Std.Concurrent.ScopeSearch related declarations