3 ms·
Sure, and every `x, err := f()` shadows any previous `err`. This kind of shadowing is totally normal and idiomatic, in no way bad.
by kiitos 2y ago
Sure, and every `x, err := f()` shadows any previous `err`. This kind of shadowing is totally normal and idiomatic, in no way bad.
- zachmu 2y agoerr has the same problem as ok, it's true. It's a messy, kind of embarrassing spot in the language and idioms, not something to celebrate.
- kiitos 2y agoI'm not sure how useful it is to adjudicate what is ultimately just a property of the language. It's not something to celebrate, or mourn, or (importantly) try to work around, it's just the way things work. It seems like you're just fighting the language. This is not the path to success :)