Page 1 of 1
7.0.1 Fixes
Posted: Tue Apr 30, 2019 5:53 am
by gray
Type tests on expressions (e.g. array elements and individual fields of records) are handled correctly in IS expressions. Type tests using CASE statements can only be performed on (qualified) identifiers, not expressions.
1) Does this apply to all type tests, or only in leaf procedures?
2) Is dereferencing via p^ considered an expression?
Re: 7.0.1 Fixes
Posted: Tue Apr 30, 2019 11:35 am
by cfbsoftware
1. The same rules apply to type tests in Leaf procedures as for type tests in normal procedures and vice versa.
2. Refer to the syntax definitions in the Appendix
The Syntax of Oberon in the Oberon Language Report.
^ is defined as a selector. This can be traced all the way back to an expression. A qualident is defined as:
qualident = [ident"."] ident
where ident = letter {letter | digit}
For more details refer to Section 7.3
Type Extension CASE Statements in the
ARM Cortex-M Oberon Programmers Guide which you can download (along with the Language Report) from:
https://www.astrobe.com/Oberon.htm