▲ | dwb 2 days ago | |||||||
Why? | ||||||||
▲ | nikolayasdf123 2 days ago | parent [-] | |||||||
zero value. container-agnostic initialization. say your type is not struct anymore, you would not have to change the way you intialize it. what you care here is zero value, and let the type figure out that it is zero and use methods appropriately. and it is just more clean this way here is google guideline: https://google.github.io/styleguide/go/best-practices#declar... | ||||||||
|