« Estimation | Main | Sharp vs. Blunt Instruments »

Eating Steak With A Spoon

Ending the Era of Patronizing Language Design

I linked, indirectly, to this article the other day and, after reading it again, I agree completely. Well, I agree completely with the notion that we should stop accepting "we didn't put that feature into the language because you're too stupid to use it" from language designers.

You really should read the comments accompanying the article, some are wise, many are interesting, unsurprisingly many seem to be commenting on a totally different article.

Now, what this doesn't mean is that every language should have every feature, it just means that presumed incompetence isn't an acceptable reason for not having it. Languages need to be designed with taste, discrimination and a desire to facilitate developer productivity.

For too long we have been told by programming language designers that we should eat our steak with a spoon because knives are too dangerous.

What sort of features am I thinking of here? Well, Java is a major culprit of the "you're too stupid" mindset.

Automatic memory management : This isn't the sort of feature I'm talking about. This is an enabling feature, something added to the language to help developers. Does it have drawbacks? Sure it does, there are times when direct-to-the-metal can be useful. But a decision was made here to facilitate in one area and compromise in another.

Operator overloading : Can it be used for evil? Sure. So can talcum-powder.. that doesn't mean we should ban it and force our babies to suffer from trench-nappy-region. There are many cases where operator overloading makes sense and its absence in Java is painful. Exhibit 1 'BigDecimal'.

Immutable Strings : Another case of "not what I'm talking about". Mutable Strings can be useful and powerful, but not having them brings advantages too. This was a conscious decision.

No meta-model : Without a meta model programmers dive into byte code manipulation and magical "doesn't work like anything else in the language" constructs like DynamicProxy. Can meta-programming be hard and weird? Sure, so is physics. Shall we ban that? It isn't the same, I hear you cry. You're damn right it isn't. Those guys created the atom bomb, and we still let/encourage/train/pay people do it. Heck we teach physics to CHILDREN. There are times in this world, when nuclear fission is just plain useful.

The list goes on.

Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
All HTML will be escaped. Hyperlinks will be created for URLs automatically.