Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I have it in my mind that Wirth floated modula/modula-2 variants into the early round of Ada candidates but I can find nothing evident.

My back reasoning to it's truth is threefold:

1) He did a residency at York university relating to pascal and modula in teaching CS. That's why my first uni language was pascal. (He'd just left)

2) York used pascal and modula heavily across the Ada specification window

3) York got an SERC or other funding contract to implement a multi pass Ada compiler on BSD Unix.

Which would mean (if true) Dijkstra's comments basically slated all of the candidate languages, and by implication Wirths language views, given he'd worked on the IFIP programming language specification process and was so strongly associated with pascal variants of imperative programming languages.




Modula was first described in March 1976.

Modula-2 is a much later language, from 1982, 3 years after the publication of Ada, and this is the version of Modula that has become well known. The first version of Modula has seen very little use, if any.

The first version of Modula has been conceived by Wirth while he took a sabbatical year during which he stayed at Xerox PARC. There he was impressed by the language Mesa, which already had modules.

In my opinion, Mesa was a programming language vastly better than any Modula version. Wirth however thought that Mesa was a too big language, so he attempted to design a simple language that offered some of the benefits of Mesa.

In 1976, when Wirth has designed the first (not very good) version of Modula, the DoD requirements specification process that has resulted in Ada had already passed through 3 stages: STRAWMAN (1975-04), WOODENMAN (1975-08) and TINMAN (1976-01), though the first requirements document that was close to the final language, IRONMAN, would be published only next year, in 1977. (The final DoD requirements document was STEELMAN, in 1978-06, and Ada was published one year later, in 1979-06.)

Therefore Modula had no influence on Ada.

After implementing the detailed DoD requirements (which included some influences from the language Jovial, which was used within the DoD at that time), the remainder of Ada was influenced by IBM PL/I, by Algol 68, by Pascal from Wirth, and also by Xerox Mesa, the source of inspiration for Modula. Any resemblance between Ada and Modula comes either from Pascal or from Mesa, which have been sources of inspiration for both Ada and Modula.

Xerox Mesa has been a very innovative programming language, but it is seldom mentioned today, despite being the origin of many features added to later languages, e.g. the less usual loop syntax used by Python (with ELSE; Mesa used a better keyword, FINISHED).

Unfortunately some of the best features of Mesa are not supported at all or only badly supported in most modern languages.


And the foundation of one of the very first memory safe systems programming languages, with automatic resource management, using a mix of reference counting with a cycle collector, Cedar.

"Eric Bier Demonstrates Cedar"

https://www.youtube.com/watch?v=z_dt7NG38V4

Mesa also provided the very first IDE experience for strongly typed languages, with code completion, typo correction, dynamic code loading, a REPL, incremental compilation,...

"The Mesa programming environment"

https://dl.acm.org/doi/10.1145/800225.806843

Indeed, so many still catching up to Xerox PARC vision.


>Unfortunately some of the best features of Mesa are not supported at all or only badly supported in most modern languages.

Excluding its epic exception handling system, what would you suggest?


There were many useful details in the syntax of various statements and expressions, which could simplify programs.

An important feature was that Mesa was one of the few programming languages that specified a GOTO instruction in the right way.

Mesa had a restricted GOTO (following suggestions from Knuth), which could jump only forwards and only out of a block.

This eliminates all problems that can be caused by GOTO, while retaining all the benefits.

All later languages are either languages that provide only an inadequate handling of errors and exceptional conditions, or languages that provide GOTO instructions that are hidden behind different mnemonics that do not use the words GO TO.

For instance, if a language has labeled loops and some kind of exit-loop instruction that contains a loop label, to be able to exit from multiple nested loops, that instruction is just an ordinary GOTO instruction, which uses a different mnemonic, because the mnemonic GOTO is "harmful", and where the jump label is located in a wrong place, which makes more difficult to follow the control flow when reading the program.

In general, in Mesa the syntax for any kind of block or iteration could specify in a simple way both a normal exit and several exits corresponding to various kinds of errors or exceptional conditions.

The syntax used by Mesa for this was more convenient than the use of exceptions in most modern programming languages and the implementation was much more efficient, because the kind of exceptions used in modern languages is designed only for returning from several levels of nested functions that have been compiled separately. For exiting one or more levels of nested blocks inside a function much more efficient implementations are possible.

Mesa also had the kind of exceptions used in modern languages, but their use was needed much less frequently.


Thank you for the tip. I'm feeling pretty stupid having never heard of (or not remembering) Xerox Mesa. (I'm just old enough to have briefly used Xerox Star.)

> ...restricted GOTO, which could jump only forwards and only out of a block.

I guess that's roughly how I imagined how GOTO / "better" exception handling should work. I've long wanted (wave arms) Visual Basic style error handling, but "inline" (not off to the side). I probably unwittingly gleaned the notion from Mesa.

I'm now foraging for Mesa stuff. Here's two quick hits.

https://en.wikipedia.org/wiki/Mesa_(programming_language)

Mesa Language Manual v5.0

https://doc.lagout.org/science/0_Computer%20Science/0_Comput...

Hopefully I'll find a working implementation.


The history of exceptions is discussed in [1]. I am not a historian, but think that Milner's ML was the first language with a type-safe exception mechanism. [2] Discusses, among many other things, Lisp's relation with exceptions.

[1] B. G. Ryder, M. L. Soffa, Influences on the Design of Exception Handling. https://dl.acm.org/doi/10.1145/885638.885644

[2] G. L. Steele Jr, R. P. Gabriel, The Evolution of Lisp. https://www.dreamsongs.com/Files/HOPL2-Uncut.pdf


Counterpoint: Wirth burned out of the Algol-68 standardization effort. He definitely did not want to get into a militarized version of that process.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: