4 ms·
Monadic Try, biased Either, Some, pattern matching and destructuting... you don’t even need to know category theory to use and understand them in code, and you
by eecc 8y ago
Monadic Try, biased Either, Some, pattern matching and destructuting... you don’t even need to know category theory to use and understand them in code, and you let the compiler do all the tough work.
This example - despise the perplexing celebrations - is a product of the limits of Go
- danieldisu 8y agoYet you can argue that despite it's limitations they could make working (complex) software with it.
- masklinn 8y agoThat's not an argument, that's a truism. You can make working (complex) software using nothing but machine code keyed into volatile memory via front-panel switches.
- martinlaz 8y agocan you really?
- lmm 8y agoIsn't that a case of "shit crayons"? People can and do make great things with terrible tools, but that doesn't make those tools any less terrible.
- dragonwriter 8y ago> This example - despise the perplexing celebrations - is a product of the limits of Go All coding style is a product of the limitations of the language (well, except when it is coding style dictated by the limitations of a different language applied in a cargo cult fashion out of it's appropriate context); and celebrating the choice of how to approach this problem given that it was being done in this language isn't the same as celebrating the language choice. Go would be pretty close to my last choice for anything, but that doesn't stop me from recognizing this as a thoughtful way to apply Go to this problem.