[Oberon] LOOP conversion

Joerg joerg.straube at iaeth.ch
Mon Jan 4 10:30:48 CET 2021


REPEAT
  Step;
  IF ~cond THEN CodeBlock END
UNTIL cond


Jörg

Am 04.01.21, 10:15 schrieb "Oberon im Auftrag von Bernhard Treutwein" <oberon-bounces at lists.inf.ethz.ch im Auftrag von oberon at wildwein.de>:

    Our russian friends had a very long thread about conversion of LOOP - EXIT
    	https://forum.oberoncore.ru/viewtopic.php?f=82&t=2547
    it is readable and understandable with Google translate ...

    I personally think that deliberate and good use of LOOP is not that bad. 

    E.g., I find

    LOOP
      Step;
      IF cond THEN EXIT END;
      CodeBlock
    END

    more attractive and readable than

    Step;
    WHILE ~cond DO
      CodeBlock;
      Step
    END

    --
      Bernhard
    --
    Oberon at lists.inf.ethz.ch mailing list for ETH Oberon and related systems
    https://lists.inf.ethz.ch/mailman/listinfo/oberon




More information about the Oberon mailing list