[Oberon] [EXT] Re: A new dialect? Oberon+ (OBX)
Chris Burrows
cfbsoftware at gmail.com
Mon Jul 26 01:54:25 CEST 2021
On Mon, Jul 26, 2021 at 8:21 AM Skulski, Wojciech
<skulski at pas.rochester.edu> wrote:
>
> If I was to vote for a single most missing language feature, then I would ask for the underscore in names.
>
> FPGA_TRIGGER_LOCATION is much more EE-friendly than FpgaTriggerLocation. Is the Oberon-07 not meant to run on the custom firmware? It should have been more firmware friendly!
>
I reluctantly allowed for underscores in the Astrobe ARM Cortex-M
compilers and documented this extension with the following
recommendation:
----------------------------------------------------------------
"Underscore characters (_) are allowed in identifier names (i.e.
constant definitions etc.). This feature is solely intended for use
with multi-word uppercase identifiers. Normally uppercase names should
only be used for Oberon's reserved words and standard procedures and
CamelCaps should be used to distinguish separate words in your own
identifier names. However a justifiable exception to this rule is the
use of uppercase peripheral register names in your programs to match
those used by microcontroller manufacturers in their documentation.
For example:
MCU.PINMODEOD0
can be defined as:
MCU.PINMODE_OD0
----------------------------------------------------------------
This language extension is something you should be able to manage to
implement yourself with the RISC5 compiler. All you need to do is
modify procedure ORS.Identifier where it's validating that the
characters are only letters or digits.
Regards,
Chris Burrows
CFB Software
https://www.astrobe.com/RISC5
More information about the Oberon
mailing list