News for hackers. Stuff that matters.
Re:Generics enabled by default in Go tip by coryrc on Saturday August 21, 2021 @01:14AM (#28254412)
Or use Option or Result, so your error handling is small and forcibly correct.
Re:Generics enabled by default in Go tip by tptacek on Saturday August 21, 2021 @01:18AM (#28254436)
Error handling in Rust isn't always small or straightforward. I miss both options and match expressions when I switch back to Go from Rust, but there's also tangles of or_else's and maps and the fact that everyone uses third-party libraries to work out the types for errors. There's tradeoffs everywhere you look.
Re:Generics enabled by default in Go tip by int_19h on Saturday August 21, 2021 @04:47AM (#28255331)
Zig is probably a better comparison for this:

https://ziglang.org/documentation/master/#Errors