3 ms·
> Pretty much a Rust noob still so maybe I'm missing something that makes this difficult/impossible though. It's largely just because the various library autho
by nicoburns 4y ago
> Pretty much a Rust noob still so maybe I'm missing something that makes this difficult/impossible though.
It's largely just because the various library authors have not managed to agree on interface definitions. I think it'll get sorted eventually, but unfortunately doesn't seem to be a big priority for the runtime developers. It's also partially blocked on async function being available in traits, which isn't currently possible in Rust without workarounds (which wouldn't be suitable for the standard library).
> Tokio would probably fit the bill, though it seems to be too complex for what I actually need
Tokio is probably what you want. It might be complex under the hood, but it ought to fairly straightforward to write networking code using it (I believe polling a channel is typically as simple as calling `.recv().await` in a loop within an async function).