|
|
|
|
|
by stickfigure
1735 days ago
|
|
Interesting but the "Isn't this just multiple return?" section seems to completely miss the point. I don't see any examples of what multiple-return would look like. And multiple-return is what I want. At first glance, it looks like this (sure, more powerful) pattern matching system is not going to satisfy my desire for a compact syntax that lets me do the equivalent of this typescript: const [foo, bar] = getMeTwoThings();
|
|
With the pattern matching the best you are going to get is nasty boiler plate like
That else clause is so terrible you'd probably just rather use the getters from the type.