Remix.run Logo
breatheoften 2 hours ago

Is there any way to implement structured concurrency on top of the std.Io primitive?

AndyKelley an hour ago | parent [-]

    var group: Io.Group = .init;
    defer group.cancel(io);
If you see this pattern, you are doing structured concurrency.

Same thing with:

    var future = io.async(foo, .{});
    defer future.cancel(io);