Why are `*` and `^` interpreted by individual Oberon commands?
Hello, I have been thinking about the design of command arguments in the Oberon System, and I would be interested to hear the reasoning behind one particular choice. When I execute something like ``` Compiler.Compile * ``` the system does not expand `*` into some representation of the marked viewer and then pass that to `Compiler.Compile`. Instead, the `Compile` procedure receives the command arguments and itself recognizes `*` and obtains the appropriate text from the marked viewer. Similarly, with ``` Compiler.Compile ^ ``` it is the command procedure itself that interprets `^` and obtains the current selection. I find this interesting when comparing it with the Unix shell model. For example, with ``` ls * ``` the shell expands `*` first, and `ls` receives the resulting list of filenames. `ls` does not need to know that the user originally typed `*`. So I am wondering: why was the Oberon command system designed so that conventions such as `*` and `^` are interpreted by individual commands rather than by the system or command interpreter? It seems that system-level expansion could make commands simpler and establish a common argument mechanism: a command could receive a text/file argument without needing to know whether the user specified it by name, by `*`, by `^`, or perhaps by some future mechanism. On the other hand, I suspect there may be a reason why this would not fit the Oberon model. Perhaps `*` and `^` are intentionally not "argument expansion" at all, but ways for a command to interact with the state of the user interface, and therefore their interpretation belongs to the command. Was this an explicit design decision? And are there advantages to having commands interpret these conventions themselves rather than putting such interpretation into the command execution mechanism? I would be very interested in how people familiar with the Oberon system design think about this distinction. Thank you, norayr
On Mon, Aug 10, 2026 at 4:15 PM նորայր <norayr@arnet.am> wrote:
I have been thinking about the design of command arguments in the Oberon System, and I would be interested to hear the reasoning behind one particular choice. ...
I recommend that you read the book The Oberon System <https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1991.pdf> - User Guide and Programmer's Manual by Martin Reiser, ACM Press 1991, ISBN 0-201-54422-9. Chapters 1 and 2 in particular discuss the features of the user interface design.
I did, and it's near me. Would you like to point out which particular page to re-read? On Tue, 11 Aug 2026 08:22:11 +0930 Chris Burrows <cfbsoftware@gmail.com> wrote:
On Mon, Aug 10, 2026 at 4:15 PM նորայր <norayr@arnet.am> wrote:
I have been thinking about the design of command arguments in the Oberon System, and I would be interested to hear the reasoning behind one particular choice. ...
I recommend that you read the book The Oberon System <https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1991.pdf> - User Guide and Programmer's Manual by Martin Reiser, ACM Press 1991, ISBN 0-201-54422-9. Chapters 1 and 2 in particular discuss the features of the user interface design.
-- There are two ways of constructing a software design. One way is to make it so simple that there are obviously no deficiencies. And the other way is to make it so complicated that there are no obvious deficiencies. -- C.A.R. Hoare
նորայր <norayr@arnet.am> wrote:
I did, and it's near me. Would you like to point out which particular page to re-read?
In Martin Reiser's The Oberon System (1991): https://oberoncore.ru/_media/library/mros1991.pdf or https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1... Page 18-19 EBNF-notation of the syntax of commands Page 34 and following 2.5 Commands Note that in this early book @ is not yet mentioned as a special character in the parameter list of a command. But in the following documents the @ is mentioned: Project Oberon (original 1992 book) page 40 Project Oberon (2005 edition) page 33 https://people.inf.ethz.ch/wirth/ProjectOberon1992.pdf Project Oberon (2013): page 33 https://people.inf.ethz.ch/wirth/ProjectOberon/PO.System.pdf Note that on page 3 of the text Using Oberon (2015, see below) the * as special character in parameter lists (referring to the marked viewer) has disappeared. Which is a pity because it is very handy when compiling modules because you don't have to select the (beginning of) the text you want to (re)compile. Even when the star marker is not visible any more the most recently marked viewer is remembered by the System. https://people.inf.ethz.ch/wirth/ProjectOberon/UsingOberon.pdf (one of the last texts Wirth wrote on the Oberon System). Regards, Hans Klaver
Op 11 aug. 2026, om 01:22 heeft նորայր <norayr@arnet.am> het volgende geschreven:
I did, and it's near me. Would you like to point out which particular page to re-read?
On Tue, 11 Aug 2026 08:22:11 +0930 Chris Burrows <cfbsoftware@gmail.com> wrote:
On Mon, Aug 10, 2026 at 4:15 PM նորայր <norayr@arnet.am> wrote:
I have been thinking about the design of command arguments in the Oberon System, and I would be interested to hear the reasoning behind one particular choice. ...
I recommend that you read the book The Oberon System <https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1991.pdf> - User Guide and Programmer's Manual by Martin Reiser, ACM Press 1991, ISBN 0-201-54422-9. Chapters 1 and 2 in particular discuss the features of the user interface design.
-- There are two ways of constructing a software design. One way is to make it so simple that there are obviously no deficiencies. And the other way is to make it so complicated that there are no obvious deficiencies.
-- C.A.R. Hoare
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
I have asked the same question on IRC and got several arguments in favor of leaving wildcard interpretation to the command. The main points were: * If the command receives the literal *, it can know that the user actually typed a wildcard. That can matter semantically. For example, a destructive command such as --- rm -f * --- could choose to warn specifically because the user used *. With Unix-style shell expansion, the command only receives the expanded list of filenames and cannot tell whether they came from *, from explicit arguments, or from some other expansion. * Not every command necessarily wants wildcard expansion. If expansion is done by the shell/system, it is imposed on all commands unless quoting or some other escape mechanism is used. If commands handle it themselves, they can decide whether wildcard syntax is meaningful. * There is an objection that every command would then need its own wildcard implementation. However the common parsing/expansion functionality can be implemented in a library. * Unix shell expansion can run into the `ARG_MAX` limit. A sufficiently large wildcard expansion produces an "Argument list too long" error because the complete expanded filename list has to be passed as process arguments. * There is also an interesting option-parsing problem. Suppose a directory contains a file named --- -rf --- Then something like --- rm * --- may be expanded by the shell into an argument list containing "-rf". From the point of view of "rm", that argument is indistinguishable from an option unless special precautions are taken. If the command itself performs wildcard matching, it knows the difference between the user's options and filenames discovered as a result of wildcard expansion. Someone also pointed out that MS-DOS traditionally followed this model: * was generally passed to the program and wildcard matching was handled by the command/program rather than expanded by the command interpreter. So after this discussion, I can see that the advantages that Oberon approach has. Keeping * or ^ visible to the command preserves information about the user's intent, avoids forcing expansion semantics on every command, and avoids some problems caused by flattening an expression into an ordinary argument list too early. norayr On Tue, 11 Aug 2026 15:10:47 +0200 Hans Klaver <hklaver@dds.nl> wrote:
նորայր <norayr@arnet.am> wrote:
I did, and it's near me. Would you like to point out which particular page to re-read?
In Martin Reiser's The Oberon System (1991): https://oberoncore.ru/_media/library/mros1991.pdf or https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1... Page 18-19 EBNF-notation of the syntax of commands
Page 34 and following 2.5 Commands
Note that in this early book @ is not yet mentioned as a special character in the parameter list of a command.
But in the following documents the @ is mentioned: Project Oberon (original 1992 book) page 40
Project Oberon (2005 edition) page 33 https://people.inf.ethz.ch/wirth/ProjectOberon1992.pdf
Project Oberon (2013): page 33 https://people.inf.ethz.ch/wirth/ProjectOberon/PO.System.pdf
Note that on page 3 of the text Using Oberon (2015, see below) the * as special character in parameter lists (referring to the marked viewer) has disappeared. Which is a pity because it is very handy when compiling modules because you don't have to select the (beginning of) the text you want to (re)compile. Even when the star marker is not visible any more the most recently marked viewer is remembered by the System. https://people.inf.ethz.ch/wirth/ProjectOberon/UsingOberon.pdf (one of the last texts Wirth wrote on the Oberon System).
Regards,
Hans Klaver
Op 11 aug. 2026, om 01:22 heeft նորայր <norayr@arnet.am> het volgende geschreven:
I did, and it's near me. Would you like to point out which particular page to re-read?
On Tue, 11 Aug 2026 08:22:11 +0930 Chris Burrows <cfbsoftware@gmail.com> wrote:
On Mon, Aug 10, 2026 at 4:15 PM նորայր <norayr@arnet.am> wrote:
I have been thinking about the design of command arguments in the Oberon System, and I would be interested to hear the reasoning behind one particular choice. ...
I recommend that you read the book The Oberon System <https://bitsavers.trailing-edge.com/pdf/eth/ceres/Reiser_The_Oberon_System_1991.pdf> - User Guide and Programmer's Manual by Martin Reiser, ACM Press 1991, ISBN 0-201-54422-9. Chapters 1 and 2 in particular discuss the features of the user interface design.
-- There are two ways of constructing a software design. One way is to make it so simple that there are obviously no deficiencies. And the other way is to make it so complicated that there are no obvious deficiencies.
-- C.A.R. Hoare
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
-- Oberon@lists.inf.ethz.ch mailing list for ETH Oberon and related systems https://lists.inf.ethz.ch/mailman/listinfo/oberon
-- There are two ways of constructing a software design. One way is to make it so simple that there are obviously no deficiencies. And the other way is to make it so complicated that there are no obvious deficiencies. -- C.A.R. Hoare
participants (3)
-
Chris Burrows -
Hans Klaver -
նորայր