2 ms·
Async-await isn’t just futures or promises. It’s compile-time + runtime mechanism that builds those promises from the code that looks like blocking calls (i.e.
by Const-me 10y ago
Async-await isn’t just futures or promises.
It’s compile-time + runtime mechanism that builds those promises from the code that looks like blocking calls (i.e. easy to read, write and debug), but uses asynchronous IO under the hood (i.e. scalable).
BTW, have you read the article you linked? Because among other things, it currently says the following:
Several mainstream languages now have language support for futures and promises, most notably popularized by the async and await constructions in .NET 4.5 largely inspired by the asynchronous workflows of F#, which dates to 2007. This has subsequently been adopted by other languages, notably Dart (2014), Python (2015), Hack (HHVM), and drafts of ECMAScript 7 (JavaScript), Scala, and C++.