Re: Language design after Algol 60

"Robin Vowels" <robin51@dodo.com.au>
Wed, 18 Apr 2018 14:58:31 +1000

          From comp.compilers

Related articles
[11 earlier articles]
Re: language design after Algol 60 robin51@dodo.com.au (Robin Vowels) (2018-04-14)
Re: language design after Algol 60 robin51@dodo.com.au (Robin Vowels) (2018-04-14)
Re: language design after Algol 60 bc@freeuk.com (bartc) (2018-04-14)
Re: language design after Algol 60 anw@cuboid.co.uk (Andy Walker) (2018-04-15)
RE: language design after Algol 60 costello@mitre.org (Costello, Roger L.) (2018-04-16)
Re: language design after Algol 60 robin51@dodo.com.au (Robin Vowels) (2018-04-17)
Re: Language design after Algol 60 robin51@dodo.com.au (Robin Vowels) (2018-04-18)
Re: language design after Algol 60 genew@telus.net (Gene Wirchenko) (2018-04-18)
Re: language design after Algol 60 martin@gkc.org.uk (Martin Ward) (2018-05-01)
| List of all articles for this month |
From: "Robin Vowels" <robin51@dodo.com.au>
Newsgroups: comp.compilers
Date: Wed, 18 Apr 2018 14:58:31 +1000
Organization: Compilers Central
References: <49854345-f940-e82a-5c35-35078c4189d5@gkc.org.uk> 18-03-103 18-03-042 18-03-047 18-03-075 18-03-079 18-03-101 18-04-002 18-04-003 18-04-004 18-04-024 18-04-034 18-04-041 18-04-046 18-04-050 18-04-063 18-04-064 18-04-074 18-04-075
Injection-Info: gal.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="90540"; mail-complaints-to="abuse@iecc.com"
Keywords: PL/I, history, comment
Posted-Date: 19 Apr 2018 01:19:20 EDT

From John Levine
Sent: Monday, April 16, 2018 10:56 PM


> [Perhaps he meant that it was impossible for *him* to master the language.
> It does have some odd rough edges, e.g., give or take my recollection of
> the syntax:


> DCL (A,B,C) CHAR(3);
> A = '123';
> B = '456';
> C = A+B;


> What does C contain? Answer: three spaces. -John]


No. IBM's PL/I for Windows compiler produces two diagnostics:


1: at compilation time, at line 6 [your line 4]:


(6:1) : IBM1211I W Source in string assignment is longer than the target C.


2. At execution time, a fatal error at the assignment C = A+B :


IBM0441I ONCODE=0150 The STRINGSIZE condition was raised.
      At offset +0000016B in procedure with entry L


Character variables were not really intended for doing decimal arithmetic,
though conversions from character to decimal are more-or-less common.


I'm not sure whether a compiler warning message would have been
produced in the 1960s with the PL/I F-compiler,
but am fairly certain that there would have been no run-time error.
[I got the three spaces in PL/I F. I dimly recall that if I turned on optimization,
it'd do constant substitution and just move the three spaces into C. Nice to hear
that they warn you off this design error now. -John]


Post a followup to this message

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