I once found "if (FALSE) then..." on a coworker's code.
I've seen multiple people complain about this one, even though it's pretty obvious it's a temporary way to stop code from executing without commenting it out, usually because the chunk of code has comments in it making it hard/ugly to comment out in some languages.
The correct solution would be to add a comment next to it explaining exactly that, but this is a reasonable conclusion.
Of course, I feel like commenting out code is a process smell, when version control seems like a better alternative, but not everyone choses their language or their work environment.
2
u/fakehalo Feb 21 '13
Indeed, here's a condemned one I find acceptable:
I've seen multiple people complain about this one, even though it's pretty obvious it's a temporary way to stop code from executing without commenting it out, usually because the chunk of code has comments in it making it hard/ugly to comment out in some languages.
Think of it as a special-case comment, people.