When I write comments for auto generated documentation it can become irrelevant after a few changes of the method. Do we have any system to automatically check, prevent such situation and warn developer to update comment? Maybe some VCS hooks?
closed as not a real question by Jim G., Walter, Glenn Nelson, MichaelT, gnat Feb 17 '13 at 19:55
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.
The best you can do is to automatically generate as much documentation as possible from the source itself.
For example, if you have code to implement a state machine, and your documentation should include a state diagram, write a program to determine the states and transitions from the code, feed to to, e.g., graphviz, and output a diagram to be included in your documentation.
If your documentation should include the calling signature of a method, extract as much of that as possible from the actual source.
If your documentation should have examples, have a system that tests the examples, and then includes relevant extracts of the tested examples in the documentation.
And so on.
But otherwise, the rest of the documentation is up to the people to maintain. And that means that procedures, not automation, are going to be the key to keeping those up-to-date.