commit | fcc97d1710b24551d3ecb18a37b7ac1faaf7e345 | [log] [tgz] |
---|---|---|
author | David Symonds <dsymonds@golang.org> | Mon Apr 07 15:00:00 2014 +1000 |
committer | David Symonds <dsymonds@golang.org> | Mon Apr 07 15:21:03 2014 +1000 |
tree | 9828e02e7011e68389f2e0b9132d899f2d0433f7 | |
parent | 83b89d4d675d8ff52139ef906e795c880fbb626b [diff] |
Recommend replacing "x := make([]T, 0)" with "var x []T". The former is almost always pointless (it's often used immediately before appending to x), and mainly due to a new Go programmer not knowing that the zero value of a slice is equally good.