2 ms·
I agree on both points. An interesting facet of your 1st point is Stroustrup's Rule [0], which gives more context for an explicit `nominal` keyword. [0] https:
by bcherny 9y ago
I agree on both points. An interesting facet of your 1st point is Stroustrup's Rule [0], which gives more context for an explicit `nominal` keyword.
[0] https://thefeedbackloop.xyz/stroustrups-rule-and-layering-over-time/ https://thefeedbackloop.xyz/stroustrups-rule-and-layering-ov...
- shados 9y agoYeah I can totally see that. I liked the classes are nominal, plain objects are structural because its close to what people expect without even knowing the difference. But yes, TypeScript was very much designed for a target audience (all of the C#/Java-style class features and namespace stuff early on, which less and less people want as time go and people learn about better ways of doing things). It seems inevitable to me that eventually (might take decades), Haskell-level type systems will be the norm and people will learn them in highschool. The world is just not ready (and neither am I)
- bcherny 9y ago> It seems inevitable to me that eventually (might take decades), Haskell-level type systems will be the norm That would be exciting, but I can't help but wonder if FP is just a matter of taste. We had Smalltalk and ML in the 70s, C++ and Erlang in the 80s, Java and Haskell in the 90s, and now it feels like all the best languages at least nod to a multi-paradigm approach: Scala, Swift, Python, JavaScript, C#, Rust, etc. The right tool for the right job, you know? > and people will learn them in highschool I'm actually working on a book along these lines! Look for it on HN in a few months :)