Re:Java 21 Released
by lolinder on Tuesday September 19, 2023 @11:56AM
(#37571828)
In TypeScript at least, async-ness is encoded in the type system, because async/await is just syntactic sugar for Promise/then/catch.
[ Parent
| on HN ]
Well, JS is paired with a single-threaded execution model, so you only have concurrency to worry about. C#, Java has proper multithreading as well, that gives another dimension to the problem.
Kotlin has multithreading, and it also puts `suspend` in the type system.
Some more examples: Rust, Python (with most/all? type checkers), C# all bake this into their type systems.