A nice small article on when it makes sense to use pointers in | CatOps
A nice small article on when it makes sense to use pointers in Go.
As with the previous article, if you write in Go a lot that would probably provide you no new information. However, if you’re just learning it or switching from another language like Python, or writing Go code not that frequent; this article should be interesting.
And a quote:
In fact, I'll quote Ben Darnell, who is the lead engineer of CockroachDB (built in Go) :
"Whenever in doubt, use a value instead of a pointer"
DevOps and other issues by Yurii Rochniak (@grem1in) - SRE @ N26 && Maksym Vlasov (@MaxymVlasov) - Engineer @ Star. Opinions on our own. We do not post ads including event announcements. Please, do no...