Hacker News new | ask | show | jobs
by Feathercrown 547 days ago
I'm a monster, I see code that's been commented out for more than 2 months or so and nuke it unless I know it's needed. We have Git, it'll be fiiine
2 comments

I bring this up in PRs, as I know with my own experience I don’t always mean to commit it commented out, sometimes it was just for testing, or it should have been deleted after I was done refactoring.
Right. The only time I sometimes leave a commented out line of code is if it's temporarily broken and will be uncommented soon; or if it's by-far the most obvious way to do something, but does not work for some reason, and then there's a comment above about why not above.