logoalt Hacker News

rerdaviestoday at 12:49 AM2 repliesview on HN

The principal difference between dispatching in a thread-based framework and async/await is that async/await allows you to program sequences of asynchronous operations much more easily. No more separation of code that initiates an async operation and the code that handles the result!


Replies

switchbaktoday at 2:42 AM

These higher level primitives that they mention provide the primitives for exactly that. This can be found in other paradigms besides async/await.

I do find that the ergonomics of this are highly dependent on a few features of a language runtime, without which it all falls apart. Or you need language specific syntax and typically a single standard implementation.

show 1 reply
marcosdumaytoday at 3:58 AM

The principal difference between threads and async/await has to be specified in at least 9 dimensions...

show 1 reply