|
|
|
|
|
by TheDong
2047 days ago
|
|
Go error handling is awful, but this isn't a fair. In go, if you write code like the following: conn, err := db.Connect()
defer conn.Close()
That defer will be run during a panic. Same thing as 'defer mutex.Unlock()'Yes, like most of go, it's manual and painful and poorly thought out, but most people do follow these patterns, so for the most part go code will safely unwind from a panic. |
|