[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: choosing a language for your audience or macros vs syntax?

> The correct structure of a classical interpreter is very well known:
> lexer/parser/bytecode compiler/VM/runtime. Adding call/cc to this
> structure amounts to adding a single function to the runtime.  Adding
> a macro expander adds a whole new phase to your implementation. You
> need lexer/parser/MACRO-EXPANDER/compiler/..., ...

Speaking as a Blub programmer, macros
(by this description) sound like they 
mainly need an extra evaluation pass.

At first, they sound nice, because
Blub's "macros" are not very useful,
and even Blubby's templates are not
really comparable (although it seems
the Standard Template Lipids have
their fans).

However, I realize I am not just a
Blub programmer, but one who works on
the Blubber system -- and Blubber has
tools which enable extra evaluation
passes.  At compile-time, I can use
"make" to automatically run source-to
source transforms; at run-time I can
interpolate not only variables but
also command output, via backticks.
(The latter is especially useful in
combination with the various little
languages available, where "little"
means that compilation/execution is
not a heavyweight step, so source
can be specialized for each run)

But, seeing that the strengths of the
Blubber system haven't been translated
to the GUI world, and considering that
I may have to return to developing for
another platform, Mugger (on which an
application that does not do most of
its work in Blub must be prepared to
install additional interpreters), is
it time I considered a Mugger-target
Lisp-like compiler instead?