Re: Closing keywords (was Re: Algol, and language design)

ok@goanna.cs.rmit.OZ.AU (Richard A. O'Keefe)
Tue, 14 Aug 90 16:36:36 GMT

          From comp.compilers

Related articles
Closing keywords (was Re: Algol, and language design) moss@cs.umass.edu (1990-07-27)
Re: Closing keywords (was Re: Algol, and language design) ima.ima.isc.com!decvax!decwrl!garth!phipps (1990-08-10)
Re: Closing keywords (was Re: Algol, and language design) ok@goanna.cs.rmit.OZ.AU (1990-08-14)
| List of all articles for this month |
Newsgroups: comp.lang.misc,comp.compilers
From: ok@goanna.cs.rmit.OZ.AU (Richard A. O'Keefe)
Keywords: Pascal, design, Algol68
Organization: Comp Sci, RMIT, Melbourne, Australia
References: <25630@cs.yale.edu> <58091@lanl.gov> <1990Aug10.035630.764@esegue.segue.boston.ma.us>
Date: Tue, 14 Aug 90 16:36:36 GMT

In article <1990Aug10.035630.764@esegue.segue.boston.ma.us>, writes:
> As far as the syntax is concerned, Modula deviates from its ancestor
> Pascal in an essential respect: statement structures consistently
> follow a single guiding rule. Every structured statement begins with
> a keyword (uniquely identifying the kind of structure) and ends
> with a closing symbol.


The curious thing about this is that Pascal was designed at least in part
as a reaction *against* Algol 68, in which the "arms" of structured
statements were "serial clauses" and each structured statement had its own
kind of terminator. Well, sort of. You could always use ( and ), so


begin s1; ...; sn end
=> ( s1; ...; sn )
if c1 then t1 elif c2 then t2 ... else f fi
            => ( c1 | t1 |: c2 | t2 ... | f )
case c in s1, s2, ..., sn out f esac
              => ( c | s1, s2, ..., sn | f )


though you couldn't use (..) for loops. So Modula syntax was a reversion
to the Algol 68 approach.


Does anyone know where the idea came from in Algol 68? Did Wirth ever
say why Pascal didn't imitate _that_ aspect of its distinguished predecessor?
--
[It is my impression that Algol68 sprang more or less whole from Van
Wijngaarden's (I hope that's right) brain, but I haven't dug into its
history in any detail. There is lots of great stuff in Algol68 that is
slowly being rediscovered; any student of programming languages should look
at it. -John]
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.