Are code comments useful?
What source code comments do we mean?
We are interested in your opinion on non-public prologue code comments, that tell you what a piece of code does so that you do not have to read the actual code. We do not mean code that is released as a public API.
Example:
/**
* Registers the text to display in a tool tip. The text
* displays when the cursor lingers over the component.
*/
public void setToolTipText(String text) {...}
These are comments written before: modules/packages, classes, functions/methods or attributes but <b>not</b> in inline comments that explain what single statements do.
Counter-example:
/* process each element's data */
updatePattern(i, returnedElements[i]);
We are grateful for the time you invest into our questionnaire.