One of my favorite geeks, “MJD”:http://www.plover.com/ just did a blog entry where he talked about the “ratchet effect”:http://www.plover.com/blog/prog/featurism.html where he talks about how we tend to use the mechanical advantage our tools give us to add cruft that we _believe_ will help out ourselves, or others at a later date. Oftentimes we add in things (as the parens in his example) that we _think_ will make something easier to read, or show our intent, but in actuality this often doesn’t really help us the way we think it should.
Take for example a recent posting I made about over-optimizing a one-liner to where I had to add compiler hints for the list operations to be factored out correctly. Is this really the best way to accomplish a task? Sure, there are extra operators and parentheses attempting to make it more ‘understandable’, but it really wasn’t good outside of the one-liner that I intended it because it was full of junk that attempted to make it understandable to something. And yet, it’s great to know and understand how it works.
My favorite quote comes from the very end, _”…the world is full of incompetent programmers. But no amount of parentheses are really going to help this person anyway. And even if they were, you do not have to give in, you do not have to cater to incompetence. If an incompetent programmer has trouble understanding your code, that is not your fault; it is their fault for being incompetent. You do not have to take special steps to make your code understandable even by incompetents, and you certainly should not do so at the expense of making it harder for competent programmers to read and understand, no, not to the tiniest degree.”_
How often do we, or certain languages (Beyond the social/political issues) do just that? Bending to the needs of the lowest common denominator. Do we write ourselves into corners trying to keep with a single syntactic style, a certain design pattern, or other concept?
On that vein, I’ll segway into a link that if I recall, Stuart posted in #utah this morning, “Signs You’re a Crappy Programmer”:http://damienkatz.net/2006/05/signs_youre_a_c.html to me this just seemed to tie in very well with the last part of MJD’s post.