>>>>> "Asger" == Asger Alstrup Nielsen <[EMAIL PROTECTED]> writes:

Asger> The progress in this discussion is not as fast as I'd hoped it
Asger> would be, but this demonstrates how hard a problem this is to
Asger> solve.  I propose a solution in this mail, that I hope will
Asger> move the decision a bit closer to reality.

It is not a problem to be a bit slow at selecting a macro language. We
must get it right at first try.

Asger> These problems go very much against adopting Python as the
Asger> "official" scripting language.  (At least it seems that
Asger> everybody agree that we should have an "official" scripting
Asger> language.)

Yes, in particular bundling seems a good thing to me.

Asger> Make Scheme the primary candidate language, in the form of a
Asger> very small and thus bundable scheme, like SIOD.  So we would
Asger> declare Scheme the "official" scripting language, that all LyX
Asger> come with.

OK.

Asger> Then, next to this, we have a language that is designed to be
Asger> simple and easy for beginners. Specifically it will be a
Asger> language with a syntax which is designed to be as "natural" as
Asger> possible.  Also, it will be a imperative language, because this
Asger> is the most natural thing for a power user: A list of commands
Asger> that are executed after each other, just like the commands
Asger> would appear when they are recorded by LyX.

That's fine with me.

Asger> So what do you think?  Should I download SIOD and try to embed
Asger> it into 1.1?  And then, over time, the simply Evil Scripting
Asger> Language would be developed over time.

Yes, please have a go at it. 

Asger> The main problem remaining with this solution is to decide how
Asger> to design the simple language.  But since we have another
Asger> language that seems to fit the needs of many developers, the
Asger> disagreements would be managable, and a big conflict very
Asger> unlikely to develop.  If someone disagrees too much, we could
Asger> disarm them by pointing to Scheme, which arguably solves all
Asger> problems except for syntax.  In particular, I think I could get
Asger> away with designing the language more or less the way I think
Asger> it should be.

What about the pratt parser included with siod? It provides the same
language in a script-like syntax. Example from the docs:

#!/usr/local/bin/siod -v01,-m2 -*-mode:text;parser:pratt-*-
main() := 
{writes(nil,"Hello Scheme World.\n");
 fflush(nil);
 writes(nil,"fib(20) = ",fib(20),"\n");
}
$

fib(x) := if x < 2 then x else fib(x-1) + fib(x-2)
$

JMarc

Reply via email to