Do you compile your code before committing it to the repository, even when you only change a few comments? I know comments are typically ignored by compilers, but I find myself doing this often out of habit.
It's good practice to compile the code every time prior to commit. Sometimes you accidentially edit something except the comments and thus break the code. Compiling is usually very quick and helps avoid needless pain. That's why I try to compile every time prior to commit.
I commit to git and then push my changes to an svn server everyone else uses, so I have a script that automatically rebuilds and runs tests and pushes to svn if everything passed
I can see why someone might not want to go through a compile cycle if it takes five minutes. But if that's the case, maybe you can collect all of your changes into a single compile/commit operation.
Every Commit Should Build the Mainline on an Integration Machine
I always compile before committing, the working compiled assembly should always match the working source code. In practice, you don't need to compile if you're just changing comments. But how often are comments the only thing you would change?
Remember, in .NET you can add XML comments which the compiler may read to create assembly documentation. Obviously when changing these types of comments a compile would need to be done.
e.g. in .Net, you could mess up the XML-comments and check in an unnecessary compiler warning if you are careless. So it's a good idea to compile your code every time prior to commit (as it is to run your tests before committing).
And any half decent compiler will take almost-zero time to recompile code when only comments have changed. The first parser pass should notice that no functions have changed and stop.
From personal experience, an overworked brain has tendency to key in more than just comments and not notice it. It is probably just better to compile it even if it takes a while. Will save others the headache and protect your credibility.