[net.lang] GOTO alternatives

ddb@mrvax.DEC (DAVID DYER-BENNET MRO1-2/L14 DTN 231-4076) (06/01/84)

BLISS has an interesting GOTO-substitute:  A block (standard begin-end
type of block) can be given a "label" which identifies it; this label
is used to identify that block in a "leave" expression.  Anywhere
within that block, you can say "LEAVE <name>" and you will have exited
from the named block (you can also specify the value of the block in the
leave expression).  I find this considerably superior to the "EXITLOOP 3"
approach to leaving a block other than the innermost, because the label
makes it clear to humans exactly which block is meant, and doesn't vary
if another layer of blocks is inserted later.

(Bliss also has an EXITLOOP to get you out of the innermost
loop.  It can't go out beyond that.)

As long as I'm discussing Bliss, I'd advise anybody interested in macro
pre-processors for languages to look at the Bliss compile-time facilities.
I find them orders of magnitude beyond anything I've seen supported anywhere
else, and very useful.

For flame protection, I should add that there are a number of things I
DON'T like about BLISS, it's just coincidence that this message discusses
the good points.  I find Bliss very frustrating, because parts of it are
so good and parts of it are so bad.

			David Dyer-Bennet
			...decwrl!rhea!mrvax!ddb

	Remember, Bliss is ignorance...or is it the other way?