The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: M Douglas McIlroy <m.douglas.mcilroy@dartmouth.edu>
To: tuhs@tuhs.org
Subject: [TUHS] sh and goto
Date: Tue, 15 Dec 2020 23:01:39 -0500	[thread overview]
Message-ID: <CAKH6PiVoFzGyX5-BeaE6R1FzFEhhS2o3xUa2fkicRzDni2iTGg@mail.gmail.com> (raw)

> Bourne commented on the omission of goto from the Bourne shell
...
> Was this decision contentious at all? Was there a specific reason for goto's exclusion in the Bourne shell?

I don't believe I ever used a shell goto, because I knew
how it worked--maybe even spinning a tape drive, not too
different from running a loop on the IBM CPC. There you
stood in front of the program "read head" (a card reader),
grabbed the "used" cards at the bottom and put them back
in the top feed. Voila, a program loop. The shell goto
differed in that it  returned to the beginning by running the
tape backward rather than going around a physically
looped path. And you didn't have to spin the tape by hand.

It also reminds me of George Stibitz's patent on the goto.
The idea there was to stop reading this tape and read
that one instead. The system library was a bank of
tape readers with programs at the ready on tape loops .
(This was in the late 1940s. I saw the machine but never
used it. I did have hands-on experience with CPCcards.)

Doug

             reply	other threads:[~2020-12-16  4:02 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-16  4:01 M Douglas McIlroy [this message]
  -- strict thread matches above, loose matches on Subject: below --
2020-12-15 16:02 srbourne
2020-12-15 19:44 ` Ken Thompson
2020-12-15 23:27   ` George Michaelson
2020-12-16  4:30     ` Richard Salz
2020-12-16  4:41       ` George Michaelson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAKH6PiVoFzGyX5-BeaE6R1FzFEhhS2o3xUa2fkicRzDni2iTGg@mail.gmail.com \
    --to=m.douglas.mcilroy@dartmouth.edu \
    --cc=tuhs@tuhs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).