Interpreter vs compiler



Raymond:
>     >> I have thought about always translating Maxima's input into Lisp and
>     >> then running the Lisp code, instead of interpreting the internal s-expr
>     >> representation.

>     Stavros> You could of course do this, but if you want to preserve current
>     Stavros> Maxima semantics, in the absence of additional information
>     Stavros> (declarations), you'd end up with simple things like f(x) being
>     Stavros> translated to...

>     Stavros> ...do you really want to debug
>     Stavros> running code that looks like that?
>
> No, of course not.  But you rarely need to debug the assembly output
> from a C compiler either.  Unless you're the compiler writer, in which
> case you might. :-)

But in your proposal, if I understood it correctly, there would be no
interpreter, only a compiler.  So if you get an error in the middle of
your code, it would have to be reported in terms of that running code,
not in terms of the constructs that the user/programmer entered.  In
modern compiled language environments, source-level debugging is
handled by a system which keeps track of the correspondence between
source code and compiled code (and often doesn't support source-level
debugging at higher levels of optimization).  Yet another layer to
add....

            -s