(no title)
curioussavage | 2 years ago
And I’ll push back against absolutist arguments about never writing about the “what” too.
So much moaning and whining about the possibility that the comment might get out of sync with the code. Oooh so scary.
Lazy reviewers are the real problem there.
At this point I’m almost a specialist in doing deep dives and deciphering what spaghetti code is actually doing and why. And I make damn sure to write comments to help out the next poor soul.
raytopia|2 years ago
This may just be me but does anyone else actually enjoy documenting their code?
jspdown|2 years ago
There's some excitment in identifying those, and that's where I enjoy documenting the intention of my code.
bryanrasmussen|2 years ago
mrkeen|2 years ago
No more wishy-washy than the concept of a comment explaining code.
cwalv|2 years ago
I don't always read comments. But when I do, it's after reading the code.
dmarchand90|2 years ago
The checklist includes:
1 are you using comments to manage obfuscated code? I.e. the comment isn't the problem it's the spaghetti code it makes the person feel entitled to write after
2 can the code just be a function with a clear name
3. Is the comment a non comment ?
<some others I forget the book is a great read>
That said. Plenty of times you need a good comment.