|
|
|
|
|
by ozgrakkurt
296 days ago
|
|
You don’t have to represent everything with borrows. You can just use data structures like Slab to make it cancel safe. As an example this library I wrote before is cancel safe and doesn’t use lifetimes etc. for it. https://github.com/steelcake/io2 |
|
It is just a PITA to get it fully right.
Probably need the buffer to come from the async library so user allocates the buffers using the async library like a sibling comment says.
It is just much easier to not use Rust and say futures should run fully always and can’t be just dropped and make some actual progress. So I’m just doing it in zig now