What I expect from a programming language
- language design
Perhaps I have just been exposed to too much Python in the recent months. But somehow, I feel like I have to express the qualities that I expect from a good programming language. Eiffel has these, most others don't.
- Programs have to be easier to read than write: Code not only communicates a solution from a programmer to a computer. It communicates a solution to other programmers or even a future self. You never understand a problem as good as in the moment you solve it. Capture that knowledge in clean and expressive code, and it is never lost.
- Don't allow the language to trick yourself: The language must protect us from fooling ourselves. Dangling elses allow you to see wrong control flow. Tabs and spaces cannot be distinguished, so they should carry the same meaning. A single equal sign should express equality, as we have learned in school.
- One way to do things: Multiple ways of doing the same thing only leads to confusion. It has no benefit. Software is complex enough without thousand variations of the same logic.
- As much static checking as possible: Static checking is good. Did you ever write a larger piece of code in one go, compiled it and it produced tons of errors? All these error would still be there, if you would not have static checking. You err much more than you think.
- No warnings: Every error free program should be a valid program. If it is not valid, an error should be raised. If it is valid, the compiler should shut up and compile it. Warnings create noise. Noise hinders understanding.
- Coding conventions are part of the language: Whoever thinks that a language is purely defined by "what the compiler accepts" is wrong. The job of the compiler is to translate a language into what some CPU needs for execution. A language is a culture of expressing yourself. Coding conventions are part of that culture. Syntax high-lighting and indention styles are not arbitrary.
It is a relief to express these thoughts. Now I sulk back to my job and do Python and Java.