News for hackers. Stuff that matters.
Re:Error stack traces in Go with x/xerror by Cthulhu_ on Tuesday August 24, 2021 @07:39AM (#28287442)
It looks more concise but if you're like me not into functional programming much, .map() is magic.

Consistency is more important than conciseness. Clear is better than clever. Plus, a function invocation / .map() is heavier than an err != nil check / condition.

Don't get me wrong, I appreciate the Either pattern as an alternative to if err != nil, but I also appreciate the really dumb and straightforward approach of non-clever Go.

There are no comments on this comment yet.