[plt-scheme] Industrial strength interpreters with Scheme?
Grant Rettke wrote:
> Lately I've been investigating books that use Scheme for implementing
> interpreters. As part of this investigation I've been reading comments
> on books that fall into this category, and a common criticism is that
> a book "does not demonstrate how to implement \"real world\"
> interpreters, but only \"toy interpreters\"".
>
> Said comments of course do not point in the direction of books that do
> fulfill this aim, or elaborate on what makes interpreters \"real
> world\".
>
> What is your take on this? Are there books on this topic?
This is exactly the sort of mentality that leads people to dismiss the
use of Scheme in education as opposed to Java or C++. Much of what is
done in education can be characterized as "toy" as opposed to
"real-world", but there is a reason for this. Separating the ideas from
obscuring details makes it easier to learn both. There's a metaphor I
like to use, which involves standing outside a building trying to get to
the roof. You can climb up the outside or you can go in and take the
stairs to the roof. You're in the real world, climbing up the outside,
but it's a long way down.
You posted earlier about algorithms, which is my area of research, but
before the digest reached me, Shriram gave an excellent survey to which
I could not add a single qualifying word. So let me try a symmetrical
task, though I suspect my response will not be as complete.
I found that working through the interpreters in Shriram's PLAI text
taught me a lot, even after several years of teaching using Scheme and
reading various texts and research papers. I didn't use his type system;
instead, I reimplemented his interpreters using s-expressions for the
source language and match.ss for the cases, trying not to look at his
code and mechanically "translate" it but instead to rederive it from the
principles articulated in the text. I like his balance of features added
to the source language, features used from the implementation language,
and intermediate steps in the derivation process.
I believe that this got me to the point where I can appreciate the
somewhat different approaches of other authors, notably the later
material in both editions of EOPL by Friedman, Wand, Haynes, and Lisp In
Small Pieces by Queinnec. Current and classic research papers are also
making more sense to me. I think I am ready for "real-world" details.
You could, of course, just start poring through the source code of any
of the many open-source Scheme interpreters. But it's a long way down. --PR