News for hackers. Stuff that matters.
Re:Implementing Go's defer keyword in C++ by kibwen on Sunday October 22, 2017 @07:47AM (#15526340)
The situation is actually a bit more nuanced in Go; an idiomatic Go library may use panic/recover internally as a means of error handling, but is supposed to convert any panics to error codes for external consumption (IOW, panics should not be a part of any public API). You can see this pattern endorsed in this blog post: https://blog.golang.org/defer-panic-and-recover .

There are no comments on this comment yet.