Home > other >  [discuss] about golang error handling
[discuss] about golang error handling

Time:09-16

You are layers of back up, I am only on the bottom, so, don't write every layer of err!=nil
For example,
Func aaa () (int, err) {
}
Func BBB () (int) {
BBB, err:=aaa ()
If err!=nil {///////do something * * *}
}
Func CCC () (int) {
Result:=BBB ()
}
Leaders together to discuss, do have a problem
  • Related