
Go 1.21 coming soon! Plus John Arundel's advice for those who aren't enjoying Go so much
Cup o' Go
00:00
The Go Linter That Tells You Don't Use in It
Clear is a function that deletes all elements from a map or zeros out all elements of a slice. It seems very counterintuitive to me from a developer standpoint. I can just imagine tons of code after this calling clear on a slice, and then setting slice equals slice zero colon zero,. Or maybe you just skip to the ladder and never call clear on a slices.
Transcript
Play full episode