This document describes a lab assignment on developing a compiler for simple expressions. It discusses lexical analysis to detect errors, constructing an abstract syntax tree, and designing a syntax-directed translator to convert infix notation to postfix. The translator is a C program that reads characters and calls functions to handle terms, expressions, and errors. It uses a global variable to pass the lookahead character between functions for translation.
Related topics: