[r6rs-discuss] Interpreters need not apply?

From: Thomas Lord <lord>
Date: Wed Mar 7 16:36:59 2007

Abdulaziz Ghuloum wrote:
>
> A "pure" interpreter, on the other hand, does none of this business
> prior to evaluation (it just interprets source-level s-expressions;
> plain and simple). I'm actually surprised to see this used in
> anything other than a homework assignment for junior-level course on
> programming languages.

While, again, "pure interpreter" is nowhere rigorously defined,
"interprets source-level s-expressions; plain and simple" suggests
you have the wrong idea in mind.

A common, directly-interpret-the-s-expressions interpreter
is an example of a "pure interpreter," sure, but, for example:

In SCM, the evaluator accepts the source datums (the raw s-exps)
and deals with them, but as each one is evaluated for the first
time its head form is in many cases rewritten into a pre-syntax-checked,
optimized form that can be more directly evaluated. On subsequent
evaluations of the same code, the evaluator sees only the rewritten
form. That rewrite process is recursive to nested forms, but lazilly
so, hence the low-latency virtues of this approach.

-t
Received on Wed Mar 07 2007 - 16:46:00 UTC

This archive was generated by hypermail 2.3.0 : Wed Oct 23 2024 - 09:15:01 UTC