Self-Documenting Code
One possible solution to not writing bad documentation is to write no documentation at all. Woo hoo! No documentation! Before you get too excited, let me explain. Modern programming languages can be quite descriptive, to the point that the code can read almost as clearly as plain English. If your code reads like plain English, what need have you for comments in plain English? None! I don’t fully buy into this idea myself, but some programmers out there believe that descriptive, self-documenting code is enough—no comments necessary. They even say that this is better than code with comments; if the code is the documentation, the documentation is never outdated. This argument has a lot of merit, and the principles behind self-documenting ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access