CST 8152 Compilers - Assignment 6
continued from page one...
The deliverables for this assignment are as follows:
By noon Friday April 11: Hand in your translation scheme and semantic explanations.
In your Lab demonstration April 16-17:
1. Hand in a disk with your complete source code. I may compile and test it later.
2. Have ready on your terminal the separate modules of your interpreter source code: the value stack, the symbol table, the scanner, the parser, and your main program.
3. Have ready good test case input and output showing how your interpreter recovers from errors and how it handles all possible input clearly and without faulting.
4. Demonstrate briefly (2-3 minutes) but convincingly that you know how your interpreter works. (See the questions in Assignment 5.) Be prepared to run a series of challenging test input files during your demonstration.
Notes on this assignment:
1. The program must be modular: The only universal global variable allowed is the lexical token structure. The value stack and its access functions must be isolated in one file, the symbol table and its functions in another file, the scanner and its functions in another file, and the parser and its recursive functions in another file. Use static to confine all the associated data structure definitions to each file. Only the global access functions for each module may be visible outside the module.
2. PRINT and DUMP are tokens matching the keywords print and dump. PRINT takes a set of expressions to be printed. DUMP prints zero or more numbered entries from the symbol table, or it prints the whole table if no number is given.
3. See Assignment 5 for details on assignment statement type checking. Make sure that the arithmetic operators are not applied to strings. (Option: Permit + to perform string concatenation, e.g. hero = Bat+man+\n; print hero; )
4. I must have time to review your annotated translation scheme before I see your program demonstration. Note: I will not review late schemes during Lab hours.
You have about 3-4 minutes of Lab time to demonstrate your interpreter, prove that it works, and show that you know how it works. Your mark for this assignment is determined by the clarity and efficiency of your in-Lab demonstration and by how well you can explain how your interpreter works.
Organize your Lab presentation! Have all the requested source module and test files open and ready to display. Three minutes is not very much time to get full marks.