News for hackers. Stuff that matters.
Re:Learn Go in five minutes by enw on Tuesday January 05, 2021 @12:04PM (#25647645)
How would you design the error handling?

Personally I'm glad Go has stayed out of exceptions (panics don't count), at scale it's so much easier to reason about flow.

Re:Learn Go in five minutes by bmn__ on Tuesday January 05, 2021 @12:28PM (#25648031)
Monadic error handling like in ML work-alikes, Rust etc. would be a good start. Adopt:

• https://github.com/rebeccaskinner/gofpher

• https://speakerdeck.com/rebeccaskinner/monadic-error-handlin...

I've been talking to the local Go user group. No one even knows about that concept. This continues a pattern of general ignorance/lack of looking beyond one's horizon I've noticed.