August Karlstrom
2010-10-13 18:13:46 UTC
The permissible syntax of (non-numeric) character constants and strings
has changed more than once since the original definition of the Oberon
language. In Oberon-2 we can express every character constant including
quotation mark and apostrophe (any string of length one can be used as a
character constant). In Oberon-07, however, it is not possible to use an
apostrophe in a character constant so instead we have to add a constant
declaration like
CONST apos = 27X;
which feels a bit awkward. I can't see why Oberon-07 didn't adopt the
definition of character constants from Oberon-2. Does it have any subtle
drawbacks?
/August
has changed more than once since the original definition of the Oberon
language. In Oberon-2 we can express every character constant including
quotation mark and apostrophe (any string of length one can be used as a
character constant). In Oberon-07, however, it is not possible to use an
apostrophe in a character constant so instead we have to add a constant
declaration like
CONST apos = 27X;
which feels a bit awkward. I can't see why Oberon-07 didn't adopt the
definition of character constants from Oberon-2. Does it have any subtle
drawbacks?
/August
--
The competent programmer is fully aware of the limited size of his own
skull. He therefore approaches his task with full humility, and avoids
clever tricks like the plague. --Edsger Dijkstra
The competent programmer is fully aware of the limited size of his own
skull. He therefore approaches his task with full humility, and avoids
clever tricks like the plague. --Edsger Dijkstra