I'm sometimes a bit paranoid in the opposite direction. I will write functioning code, then add some comments, then think "but what if my comments somehow messed up the code!?" so I have to run it again every time I add a comment to make sure it still works. Although I suppose that's not entirely nonsensical since there's always the chance you accidentally comment something out or make some other accidental change while writing the comments, so it might not be a bad practice.
1
u/MChainsaw Jul 20 '18
I'm sometimes a bit paranoid in the opposite direction. I will write functioning code, then add some comments, then think "but what if my comments somehow messed up the code!?" so I have to run it again every time I add a comment to make sure it still works. Although I suppose that's not entirely nonsensical since there's always the chance you accidentally comment something out or make some other accidental change while writing the comments, so it might not be a bad practice.