| ▲ | ngruhn 7 hours ago | ||||||||||||||||
> async/await came out of C# (well at least the JS version of it). Not sure if inspired by it, but async/await is just like Haskells do-notation, except specialized for one type: Promise/Future. A bit of a shame. Do-notation works for so many more types. - for lists, it behaves like list-comprehensions. - for Maybes it behaves like optional chaining. - and much more... All other languages pile on extra syntax sugar for that. It's really beautiful that such seemingly unrelated concepts have a common core. | |||||||||||||||||
| ▲ | rafaelmn 7 hours ago | parent [-] | ||||||||||||||||
I knew someone was going to bring up monads that's why I put JS version :) JS took the C# syntax. | |||||||||||||||||
| |||||||||||||||||