Hacker News new | ask | show | jobs
by butterisgood 2552 days ago
It looks like a monad for Either or Result to me, and I think it's an improvement.

The good news is if you hate it you don't have to use it, but since it'll be in the language (if they take it) you'll have to know how it works.

I don't think this is worse than things like "for:else" in Python.

1 comments

Interesting to go with Monad "by convention". They wont build in an explicit type but rather utilize convention (placing err as the last param and giving it a certain shape) to replicate that behavior
Yep. Being practical and simple with easy to remember rules seems to be more of a value to the designers than to build a language with “features from Ivory Towers” (in the Haskell sense anyway).

The designers hope to give Go users “what’s needed to write good code” without having the learning curve of other languages.

I suspect this balance is hard to strike at times and I rather admire their efforts.