3 ms·
Can someone explain to me the difference between this and futures (specifically, futures in c++11)?
by 10098 13y ago
Can someone explain to me the difference between this and futures (specifically, futures in c++11)?
- platz 13y agoI can't comment on futures in c++11, but async/await is more like promises + coroutines, rather than just promises (as defined by Promises/A+)
- fauigerzigerk 13y agostd::async uses threads (if used with std::launch::async) whereas C# await uses coroutines. You can use Boost.Coroutine to implement something similar in C++ as that project has done: https://github.com/vmilea/CppAwait https://github.com/vmilea/CppAwait