[Oberon] Would this work for ETHO?

eas lab lab.eas at gmail.com
Thu Sep 24 07:07:21 CEST 2015


Newsgroups: comp.lang.oberon

I created an <automatic menu syntax-directed multi-language> writer,
[the next stage after syntax coloring] some months ago, and after
being diverted to urgent problems, couldn't see how to use it, now
that I'm free to continue refining it.

Writing *THIS* will help me SELF-explain how it works?
It uses wily: the public domain version from plan9, copied from ETHO.

Using ETHO terminology:
 midMouse = MM = Execute the Command [with name = token-klicked-on].
wily doesn't have ETHO's restriction: that a valid command is <M.P>;
but let's see for ETHO.

So, at the start, the user loads a TextFrame containing only:
  START.p

START.p is a command [M.P in ETHO terminology] which:
 replaces the textString "START.p" with eg. the 7-lines:
"MODULE ModID;
CONST ConstDecls.p;
VAR VarDecls.p;
PROCEDURE ......
BEGIN
  Statements.p
END ModID."

And eg. Statements.p is a command that
replaces the textString "Statements.p" with eg.
" KnownID.p := Expression.p
IF ............
WHILE ............
REPEAT ...........
FOR ...........


END ....
------------------------------
So, essentially klicking any <hot Tokens> replaces it
with it's expansion.

It's a type of syntax directed menu.

Let me get back to wily, and you write an ETHO prototype.
Oh, for ETHO you'd use eg:
x.START , x.ConstDecls , x.Statements ,x.Expression



More information about the Oberon mailing list