I want you to give up programming


We’re programmers, you and I.  We are time-served, battle-hardened veterans.  We have honed our objects, learned our digital ropes, intoned the Laws of Liskov and Uncle Bob, and we’re now pretty good at what we do.

And now I want you to stop what you’re doing.  I want you to give up all that programming that you know and love, and I want you to do something else.

Look at your IDE.  Look at the menus and buttons and hierarchical whatchamacallits and text-filled panes. You know, because you’re a sophisticated developer that none of that is real – it’s all just an appearance of reality, pixel-thin and brought to life by the operation of the software.  That’s what software does: it creates the illusion of reality, and we developers: we’re magicians, summoning the appearance of reality out of nothing at all.

The tools of our trade, the incantations that create those illusions, are objects.  We are trained to think in objects – hands up anyone who wouldn’t claim to be an expert in object-orientation! – and yet there is nowhere in the executing machine code, nowhere on the chip surface where those objects reside.  The objects that we use to construct our illusions are themselves illusions summoned by the same process.  We are seduced by our own glamours.

Deep down, deep in the machinery of the universe, there are some fundamental laws and constructs from which computer ideation is constructed, but objects are not among them.  Objects are, in fact, as contingent and as arbitrary and as conventional as the depictions of the controls on our applications – no more fundamental or senior than Windows’ widgets are senior to Apple’s alternatives.  Objects are not fundamental units of computation: they’re not even necessary.  They’re just the approach we happen to take.

Objects are not necessary for programming.  Through the history of computer science, many other approaches have been proposed and explored.  Alan Kay, the (self-proclaimed) inventor of objects, claims that what passes for objects today is no relation to what he constructed, and thinks we should rediscover the multiple-dispatch that made Smalltalk unique.  Javascript offers raw access to decorators from which objects (as well as other, more-or-less object-like things) can be constructed and micromanaged.

But, let’s stray even further from familiar territory.  Functional programming does without objects, or procedures, or even variables of any kind.  Functional programs don’t do anything, they are things.  They are closer to the software-magical idea of illusion than objects (and they’re much closer to the mathematical concept of computation).  Functional languages put you more closely in touch with your task and with your user.  They’re simply a better way to program.

This is a strange and foreign place, where nothing ever happens, and yet everything happens at once. It’s a place where hard things become simple, and simple things are trivialised out of existence, but some trivial things turn out to be impossible.

Functions, too, are illusions, created by carefully-crafted software operating inside the machinery.  But they’re a very different illusion to objects, and nothing you’ve learned in a lifetime of object-orientation will prepare you for this.

So, I’m asking you to give up programming – or at least everything you have learned about programming and believe is true.  I want you to give functions a go.


Jobs at the trainline: Agile Developer

trainline logo

 

 

 

5 thoughts on “I want you to give up programming

  1. Great article, interesting approach, deep and clear vision. But, for an experienced developer that used to think in OOP, and low level codes and hard code management, the illusion of being in control of every process step is wonderful. We spend a lot of time to learn it, and of course is not easy to let it go … I think the best approach to this matter is “Open your horizons to a new way to do it” 😉

  2. Hmm, I think we can make more pragmatic argument for trying out functional programming, and leave the New Age mysticism out? Lots of nominally OOP languages, like Java, are even getting better support for first class functions these days, so they are already trying to bridge the gap.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s