-
Book Overview & Buying
-
Table Of Contents
Building Programming Language Interpreters
By :
While reducing the scope of goals is a natural outcome of achieving the first release of any software product, the acceptance criteria set a much more precise bar for success.
As with the goals, let me walk you through each one of them.
For an interpreter that handles network protocols, I set as a principle that the interpreter should only be initialized once, especially in the case of a network server, as it will have to handle the same protocol multiple times. This was something that I carefully kept in mind throughout the design and implementation of the interpreter. From the very beginning, I started with the InterpretedProgram type, which contains a read-only execution model for the program.
This has driven not only how the interpreter itself was designed, but also how the translation of source code into the executable instructions in the form of the read-only OpTree objects allows the reuse of those...