|Re: what is defined, was for or against equality email@example.com (Thomas Koenig) (2022-01-06)|
|Re: what is defined, was for or against equality firstname.lastname@example.org (David Brown) (2022-01-07)|
|Re: what is defined, was for or against equality email@example.com (Spiros Bousbouras) (2022-01-07)|
|Undefined behaviour, was: for or against equality firstname.lastname@example.org (Martin Ward) (2022-01-07)|
|Re: Undefined behaviour, was: for or against equality email@example.com (David Brown) (2022-01-07)|
|Re: Undefined behaviour, was: for or against equality firstname.lastname@example.org (Spiros Bousbouras) (2022-01-08)|
|Re: what is defined, was for or against equality email@example.com (Thomas Koenig) (2022-01-08)|
|[16 later articles]|
|From:||Martin Ward <firstname.lastname@example.org>|
|Date:||Wed, 5 Jan 2022 10:25:37 +0000|
|Injection-Info:||gal.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="84231"; mail-complaints-to="email@example.com"|
|Keywords:||PL/I, history, comment|
|Posted-Date:||05 Jan 2022 12:11:32 EST|
On 04/01/2022 21:26, gah4 wrote:
> Stories are that COBOL programmers always
> keep the list of reserved words nearby, to avoid using them.
Our esteemed moderator claims:
> [COBOL doesn't have that many reserved words
I count 510 reserved words in IBM COBOL. Adding a few other dialects
can push the total to 700 or more. By comparison, C has about 32
The story I heard was of a COBOL shop where it was mandatory to
include a hyphen in every data name: in effect, *every* unhyphenated
word was treated as a reserved word. The slightly more managable list
of *hyphenated* reserved words (149 in IBM COBOL, but 46 of these are
of the form COMP-0, COMP-1, COMP-2 etc) was printed out and posted on
I just noticed that if you include a digit in the part of the name
before the first hyphen, you can guarantee to avoid all
the reserved words!
PL/I went to the other extreme of no reserved words in reaction
to COBOL. Also, the aim of PL/I was to be a language which does
everything: business programming (like COBOL) and scientific
programming (like FORTRAN). In theory, if you only wanted
to do, say, business programming, you only needed to learn
part of the language and you would not get tripped up by keywords
from the other part of the language that you didn't know about yet.
Using a language that you don't know in its entirety might seem
dangerous, but everybody seems to do it these days:
how many C programmers have read the entire 500+ pages of
the latest C standard and memorised the 200+ varieties
of "undefined behaviour" so that they can avoid all of them
in every line of code that they write?
Dr Martin Ward | Email: firstname.lastname@example.org | http://www.gkc.org.uk
G.K.Chesterton site: http://www.gkc.org.uk/gkc | Erdos number: 4
[IBM hoped everyone would switch from Fortran and COBOL to PL/I and
it was obvious Fortran programmers would not put up with reserved
words, particularly ones unrelated to scientific programming.
As far as the size of languages, that seems a matter of point of
view. Python is a large language if you consider the standard
library to be part of the language, a very small one if you don't.
Return to the
Search the comp.compilers archives again.