News for hackers. Stuff that matters.
Re:Thoughts on the “Guard” Proposal for Go's Error Handling by klabb3 on Sunday November 06, 2022 @01:05AM (#33489653)
As someone who likes Go, agreed 100%.

Sum types + pattern matching + tuples alone are so powerful, they could fix like top 5 of my biggest annoyances with Go.

Add some syntax sugar (like '?' from Rust), and it fixes a majority of the boilerplate issues.

Imo, people praise Rust too much for the ownership and safety story, and way to little for its (more simplistic) excellent decisions around simple types.

Re:Thoughts on the “Guard” Proposal for Go's Error Handling by baq on Sunday November 06, 2022 @04:03AM (#33490609)
A bit of a tangent here but a similar thing happened with Python 2->3: people focus on Unicode (especially native English speakers) and completely forget that exceptions were made unbroken.
Re:Thoughts on the “Guard” Proposal for Go's Error Handling by masklinn on Sunday November 06, 2022 @08:40AM (#33492517)
I can’t think of anything which was broken exceptions-wise in p2, and was unbroken in p3. Are you talking about the addition of exception chaining?
Re:Thoughts on the “Guard” Proposal for Go's Error Handling by baq on Sunday November 06, 2022 @12:15PM (#33494820)
That, string exceptions, raise from, etc.