-
Book Overview & Buying
-
Table Of Contents
Building Programming Language Interpreters
By :
When implementing the interpreter runtime, it’s important to visualize a real example of the usage of the language to identify which operators need to be implemented. In this case, laying out the operations for writing and parsing an HTTP message helped identify various new operators and helped create test cases that demonstrated that they work as expected.
With those particular needs identified, I could focus on implementing each operator, finalizing with a test case that showed that the interpreter was able to parse a message to a data structure and then use that data structure to reproduce the same message.
With that, I could get to build what the API for the user of the library would look like, and build a test case that exercised the interpreter in a very real scenario, integrating with a specific I/O library to have a basic HTTP server and client communicate over real network sockets.
This closes the work on the runtime of the interpreter. In the next...
Change the font size
Change margin width
Change background colour