🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.misc
Article #5244

Re: From Modula to Oberon

#5244
From: Erik Jacobsen
Date: Fri, 04 Mar 1988 09:30
28 lines
1550 bytes
In <2787@enea.se> Erland Sommarskog (sommar@enea.se) makes many good
points about Wirth's new language, Oberon, but also deplores the
removed FOR-loop. He gives an example, and writes:

>  ... (OK, 
>  depends on how FOR is implemented ...

That is in fact the problem with FOR-loops - at least as they exist
today.

At one time I had access to 5 different PASCAL-compilers, and could write
a program with one FOR-loop, that would give 4 different results when
executed, and one that wouldn't compile.

This problem does not exist with WHILE/REPEAT-loops, and removing
the FOR-loop from a language is one effective way of making it
cleaner.

Another way is to define what the FOR-loop actually means in one
particular language, and today there is a PASCAL-standard. But
we still have old compilers, and we have FOR-loops in other languages,
that look the same, but behave differently.

If you write programs for portability, you must know what subset of
valid FOR-loops will compile and execute correctly in all implementations
of the langauge (and possibly in other languages), and otherwise use
WHILE/REPEAT-loops.
Technical Details
Message-ID: <1345@daimi.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!mcvax!diku!daimi!erja
References: <7161@sol.ARPA> <2787@enea.se>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!mcvax!diku!daimi!erja
From: erja@daimi.UUCP (Erik Jacobsen)
Newsgroups: comp.lang.misc
Subject: Re: From Modula to Oberon
Message-ID: <1345@daimi.UUCP>
Date: 4 Mar 88 09:30:16 GMT
References: <7161@sol.ARPA> <2787@enea.se>
Reply-To: erja@daimi.UUCP (Erik Jacobsen)
Organization: DAIMI: Computer Science Department, Aarhus University, Denmark
Lines: 28
Keywords: FOR