Upthrust

This is the weblog of Milinda Pathirage

Tag: clean code

Comments

Nothing can be quite so helpful as a well-placed comment. Nothing can clutter up a module more than frivolous dogmatic comments. Nothing can be quite so damaging as an old crufty comment that propagates lies and misinformation. Comments are not like Schindler’s List. They are not “pure good.” Indeed, comments are, at best, a necessary [...]

Writing Readable Code Matters

Function names matter: we’ve known this for a long time, but now we know that we scan function names first. A good name, and you don’t need to focus on the implementation all that much. Variable names matter: again, nothing new. Notice, though, how the eye goes back to the variable definition and assignments. We [...]