4 ms·
There are a couple of different objections to this, though there is also a lot of support. The current state of it is "someone needs to write up an RFC." If yo
by steveklabnik 5y ago
There are a couple of different objections to this, though there is also a lot of support. The current state of it is "someone needs to write up an RFC."
If you want the full gory details: https://github.com/rust-lang/rust/pull/65875 https://github.com/rust-lang/rust/pull/65875
- ibraheemdev 5y agoWell that's just the "simple primitive for 'block the current thread on this async call'", which can, with the new `Wake` trait, be written in around 10 lines of code. The real change would be adding an actual runtime to the standard library.
- steveklabnik 5y agoPotato, potato. Both involve adding some form of runtime, now we’re just negotiating details. (I personally would like a very very simple one like the ten LOC version, but wouldn’t want anything more.)
- ibraheemdev 5y agoWell the block_on runtime is only meant for testing or bridging sync and async code, so it wouldn't solve the problem :)
- steveklabnik 5y agoIt solves my problem, which is why I like it as a solution (documentation, examples, and tests), haha!