3 ms·
The post makes a good point, albeit in a long-winded way. My short summary would be in languages that result in function-coloring due to async/await, using Fut
by karmakaze 3y ago
The post makes a good point, albeit in a long-winded way.
My short summary would be in languages that result in function-coloring due to async/await, using Future/Promise directly avoids the coloring and the ecosystem is better off.
Places where async/await are ok are JS (because both the browser and node/deno) are for the most part in an async context, and Go since everything's a goroutine hence all one color.
Languages such as Java have worked well with Future/CompletionStage and doesn't really need the convenience of writing async/await which translates the rest of the program after await into a hidden 'rest of program' callback. That async/await syntactic convenience is not worth the complexities added to libraries. Rust including async/await was a poor 'cargo cult' choice. I would welcome a Rust fork/ecosystem without it.
- withoutboats3 3y agoThat’s absolutely not a summary of my blog post, since I completely disagree with it. I think async/await is great and avoiding it for some reason would do nothing to mitigate the function coloring problem.
- karmakaze 3y agoSorry I meant to say my summary of the situation with asymc/await not a TL;DR of the post.