Re:Writing system software: code comments
by p0nce on Sunday October 07, 2018 @06:14AM
(#18159822)
Great article. I like "debt comments" though, no point hiding defects really.
[ Parent
| on HN ]
It depends on what kind of code you are working on. Having 'debt comments' in production code could be taken as a suggestion that code should not be in production.
What I really like are "This is fine, but with effort it could be done better like this" comments, which one might also call 'debt comments'. For example, if you have a brute-force search on something that could be done by bisection.
Let's rewrite this: there is a point to hiding defects... if you are a contractor or looking for a promotion.
Alternatively, one should address defects by fixing them not just marking them.