[Tutor] Any stuff about python interpreter design ?

Danny Yoo dyoo at hkn.eecs.berkeley.edu
Fri Mar 10 06:04:27 CET 2006

> So I take a look into the source code .But I get confused about so many
> files and functions . I want to ask that is there any stuff about the
> interpreter design and coding ?

[meta: my reply is really about Scheme, not Python.  My apologies to the
list, but it's my honest answer.]

Hi Bo,

There are several books and online material about the writing of
interpreters.  The ones that I'm most aware aware of that are aimed at
beginner programmers, though, target the language 'Scheme'.  The core
Scheme language has a fairly minimal syntax and semantics, and it's simple
enough that it's not too bad for beginner to understand (and write!) a
usable Scheme interpreter.

So you may find it useful to learn about interpreters by looking at Scheme
interpreters.  And even though it's not Python, it's still very related
and applicable; if you have a model of how a Scheme interpreter works,
you'll be better equipped to understand in general how interpreters work.

For example, the textbook "How to Design Programs":


starts covering the evaluation of a programming language by about Chapter


Here are other Scheme resources about interpretation (the first two links
contain online books):


If you have more questions, please feel free to ask!

More information about the Tutor mailing list