[Oberon] Case statements containing base type labels

Andreas Pirklbauer andreas_pirklbauer at yahoo.com
Tue Aug 29 09:43:03 CEST 2023

Isn’t the problem that the evaluation order of the Oberon “type" case statement (CASE p OF basetype .. | extendedtype.. | .. END) is not well defined. This inevitably means that different compilers will (necessarily) end up implementing different semantics.. which is bad.

In my view:

a) The type case statement should never have been merged with the “numerical” case statement - not because it makes the parser a little bit easier, but mainly because they are in fact separate statements.

b) The evaluation order of labels should be defined in the language - the order doesn’t necessarily have to be declaration order, it could for example also be defined by the type hierarchy itself (e.g. highest extension level first).

More information about the Oberon mailing list