2 ms·
Any who builds a new language and doesn’t make pattern matching a big part of the language is seriously missing out. It’s easily the #1 thing I miss syntax-wis
by dmix 7y ago
Any who builds a new language and doesn’t make pattern matching a big part of the language is seriously missing out.
It’s easily the #1 thing I miss syntax-wise after using Elixir/Erlang for any period of time.
Patterns fit perfectly with the typed and functional approach, especially with Maybe monads which are used everywhere in some apps.
- spankalee 7y agoTypeScript isn't really a new language. It's a (mostly) type-checking-only extension to JavaScript. The team has made a policy of not adding any more runtime behavior changing features. JavaScript will need to add pattern matching for TypeScript to get it.
- dmix 7y agoOh I know, I actually don't expect it from Typescript. It's portability with JS code is TS's best feature and I don't see how you could marry the two (maybe I'm wrong here). I just wanted to share how much I like pattern matching.