DescriptionWe will review concepts of high-level programming languages, and language grammars. We talk about translators, interpreters and portable compilers and then take a deeper look into compilers, decomposing them into syntactic analysis, contextual analysis, and code generation. Each of these can be accomplished by making a pass through the user program to be compiled. We spend time on each of these passes, from a theoretical/conceptual viewpoint and at the same time from examining and writing Java code. The language we will write the compiler for is called the Triangle language, and it is a subset of Pascal. Pascal is a procedural language, much like C. Throughout the course we will write small programs in the Triangle language to test our compiler.
MusicListen to the compiler, compiling this triangle program.