5 ms·
I think the author as a point though. Typescript and type annotations for python will never be able to be as good. Not only because they are not "first class",
by valenterry 6y ago
I think the author as a point though. Typescript and type annotations for python will never be able to be as good. Not only because they are not "first class", but also because they always have to interopt with potentially non-typed code.
Then, creating a good typesystem is really really hard. Even professional language designers struggle with that. Take Martin Odersky, the creater of Scala. He didn't just invent Scala, no, he learnt under his professor, then created pizza-lang and did other experiments and worked with other languages (e.g. he was the one who added generics to Java) before he used all his expertise to create Scala. And even then mistakes were made.
You can see it from the language. I work with both Scala and python (with type annotations) and you can see that one is created by a specialized professional, where the other one is created by smart people but not with the same sophistication.
> Additionally, RE "Poor performance" the author is presumably talking about CPU-bound performance.
He probably does, but these languages are most often also better for IO-bound programs. The reason is that writing asynchronous and concurrently executed code is very difficult and pretty much adds another layer of problems on top of everything someone does. Languages with static types (not only Scala) can leverage a big advantage here, because the compiler can help you to indicate what is synchronous and what isn't.