I see people claim that TypeScript is "really a linter, not a static type system" pretty often. This is a strange thing to say. It's unsound and you can turn the type system off. But that sentence is true of every popular static type system in the history of programming.
TypeScript: x as any
C: (void *)x
Java: (Object)x

This is totally normal for static type systems with widespread adoption. Java is not a "linter".
Java also isn't a linter just because its type system is less sound than Haskell. And TypeScript isn't a "linter" because it's less sound than Java.
This is an even easier argument than the ones I'm making here: https://twitter.com/larsr_h/status/1266052696974524417
Words need to mean things. It's important to be able to be able to communicate with colleagues efficiently and unambiguously.
Lots of "TypeScript seems like a linter because it can only check types at compile time, not runtime." Neither can Haskell, which is generally our prototype for "very strict static language". Runtime reflection of types is not part of what "statically typed language" means!
I think that's what you get when someone tries to imagine what a static language is, but their first-hand experience is limited to dynamic languages. They try to imagine static languages as "what I know, but slightly different". It's this problem: https://twitter.com/garybernhardt/status/1250177967650562048
This is a good time to reiterate that every programmer will benefit from taking Dan Grossman's fantastic programming languages course. It's recorded as a series of live screencasts, available for free, and taught mostly in ML. Use the "Videos" links here: https://courses.cs.washington.edu/courses/cse341/19sp/
If you've never used a statically typed language in anger, I think that course will have a huge impact on how you think about programming. It's also very accessible.
Speaking of which: https://twitter.com/mat4nier/status/1266075456563892224
Another testimonial: https://twitter.com/liammccartney/status/1266081437977108480
You can follow @garybernhardt.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.

Latest Threads Unrolled: