From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 25316 invoked from network); 1 Dec 2020 15:38:52 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 1 Dec 2020 15:38:52 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id 547629C249; Wed, 2 Dec 2020 01:38:49 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id AF14F9C204; Wed, 2 Dec 2020 01:38:27 +1000 (AEST) Received: by minnie.tuhs.org (Postfix, from userid 112) id E081F9C204; Wed, 2 Dec 2020 01:38:25 +1000 (AEST) Received: from freefriends.org (freefriends.org [96.88.95.60]) by minnie.tuhs.org (Postfix) with ESMTPS id 3F7109C203 for ; Wed, 2 Dec 2020 01:38:25 +1000 (AEST) X-Envelope-From: arnold@skeeve.com Received: from freefriends.org (freefriends.org [96.88.95.60]) by freefriends.org (8.14.7/8.14.7) with ESMTP id 0B1FcL5f023859 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 1 Dec 2020 08:38:22 -0700 Received: (from arnold@localhost) by freefriends.org (8.14.7/8.14.7/Submit) id 0B1FcLi5023858; Tue, 1 Dec 2020 08:38:21 -0700 From: arnold@skeeve.com Message-Id: <202012011538.0B1FcLi5023858@freefriends.org> X-Authentication-Warning: frenzy.freefriends.org: arnold set sender to arnold@skeeve.com using -f Date: Tue, 01 Dec 2020 08:38:21 -0700 To: jcapp@anteil.com, jason-tuhs@shalott.net References: <15511090.6330.1606835354160.JavaMail.root@zimbraanteil> In-Reply-To: <15511090.6330.1606835354160.JavaMail.root@zimbraanteil> User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: [TUHS] The UNIX Command Language (1976) X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tuhs@minnie.tuhs.org Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" In the late 70s and early 80s, structured programming was on the ascension, but had not completely captured the minds of all computer scientists and programmers. (cf. Knuth's "Structure Programming with Goto Statements" article.) It was recognized that goto was not necessary if one had proper control structures in a language (if/else, while), and that code with no (or minimal) gotos was easier to read and understand. So this kind of thing was "in the air" when Bourne wrote the V7 shell. If he's on this list, it'd be nice to hear directly from the source. :-) HTH, Arnold Jim Capp wrote: > Is it possible the elimination of the GOTO statement in the Bourne Shell > was related to a Letter to the Editor in Communications of the ACM, March 1968: > > "Go To Statement Considered Harmful," by E. Dijkstra. > > Jim > > > From: jason-tuhs@shalott.net > To: tuhs@minnie.tuhs.org > Sent: Monday, November 30, 2020 10:59:18 PM > Subject: Re: [TUHS] The UNIX Command Language (1976) > > > "The UNIX Command Language is the first-ever paper published on the Unix > > shell. It was written by Ken Thompson in 1976." > > > > https://github.com/susam/tucl > > Thanks for that. > > This reminded me that the Thompson shell used goto for flow control, which > I had forgotten. > > Bourne commented on the omission of goto from the Bourne shell, "I > eliminated goto in favour of flow control primitives like if and for. > This was also considered rather radical departure from the existing > practice." > > Was this decision contentious at all? Was there a specific reason for > goto's exclusion in the Bourne shell? > > Thanks. > > -Jason