The developer blogosphere is in a fuss about in-code comments. In my opinion, most code comments that I’ve seen are just not necessary. It’s more than possible to refactor, extract method, and rename your way to cleaner code where comments just aren’t needed. But that only describes what the code does.

Where I find code comments far more helpful is knowing the why. Why did a developer solve a particular problem in a particular way? Are there limitations or constraints that may not be clear? If you check the ASP.NET MVC source code, you’ll find that there are a lot of comments like this. They don’t describe what is going on, but they do describe why the developer chose to solve a particular problem in some fashion.