[ Go back to normal view ]

BW2 :: the bitwise supplement :: http://www.bitwisemag.com/2

Whatever Became Of Modula-2?
Modularity, where art thou?

16 April 2007

by Huw Collingbourne

For some reason, I’ve been thinking about Modula-2 quite a bit lately. Years ago, I used to program in TopSpeed Modula-2, which was created by one of Borland’s founders, Niels Jensen, and a team of ex-Borland programmers. It was a great product for its day (the early ‘90s) and, in my view, it deserved to be a massive success. The fact that it wasn’t can be attributed, largely, I think, to the dominance of C and the emergence of C++ as the PC programming language of choice at that time. Besides which, I guess Modula was just a bit too close to Pascal, and Borland had that market all wrapped up.



The great thing about the Modula-2 language was, as its names suggests, modularity. At that time, however, the trend was very much for languages to jump on the object oriented bandwagon in the belief that OOP would provide all the benefits of modularity (or ‘encapsulation’) plus a whole load of other neat stuff too.

In fact, most OOP languages from Object Pascal to C++ ended up introducing a whole load of complexity without providing anything like the same degree of modularity as Modula. Which is, I think, a great shame.

To some extent, the arrival of Java started a trend towards simplifying OOP by cutting down on the syntax and taking care of garbage collection. But modularity - real honest-to-goodness, safe, thorough, reliable modularity is notably missing from most languages these days. Yes, yes, I know, many languages give you the ability to apply degrees of ‘hiddenness’ to encourage people to define interfaces to get at data lurking inside objects, classes, modules, units and namespaces. But this free-and-easy approach is, to modularity, what a polite request to keep down the noise would be to a gang of Hells Angels on their annual weekend at the seaside.

Niels Jensen and his team went on to develop a database IDE, Clarion (rather a dull project, I always thought) which, I gather was provided with Modula-2 as an option (probably to keep the development team happy). Clarion is still available, though I don’t know how many people use it; and I rather doubt whether many of them program it in Modula.

There have also been a few ‘successors’ to Modula-2, such as Modula-3 and Oberon. But these haven’t set the world afire either.

How many people are still using Modula-2 (or a successor), I wonder? And, if not, are there any other languages that offer a similar degree of modularity? If anyone can point me to a modern implementation - preferably with a decent IDE - I’d love to hear from you...