Hacker News new | ask | show | jobs
by jerknextdoor 2618 days ago
`async`/`await` syntax hasn't been implemented. `std::future` will be stabilized in 1.36. It will be a decently long time until it's as "easy to use as it is in JavaScript".

You can follow the progress here: https://areweasyncyet.rs/

1 comments

I would say that a realistic target for being able to use async/await in general projects using the stable compiler is the end of the year. Any earlier than that you will be able to use it, but you'll be in the same situation as today: fragmented ecosystem (0.1/0.3/std futures split), incomplete or missing features, missing syntax (await/async for loops/etc.) and subpar diagnostics. Things are slowly but surely coalescing into a nice story, but right now the people that are excited are going off potential more than what is already there, as interesting as many of the individual pieces are.