69

For Sum Types: Golang's multiple return parameters are overrated

 6 years ago
source link: https://awalterschulze.github.io/blog/post/sum-types-over-multiple-returns/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client
In this Go Experience Report I am going to make a case for sum types over multiple return parameters.Analysis of multiple return parameters I wrote a little tool which does some analysis of Go source code. Thank you to the go/types library. The tool simply counts the number of times multiple return parameters are used. I ran this tool over the standard library and these are the results:

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK