{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Project3 - emit the type expressions If parsing and...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CSE 450 Project 3, Spring 2008 Objectives: Implement and use a symbol table for SpartanAda. Perform semantic analyses, specifically type checking. Description: As described in the first project, your term project involves the construction of a compiler for a language called SpartanAda , which is a subset of the Ada95 programming language. For this, the third project, you will extend your parser with symbol tables and type checking. Your program must read in the source file (whose name is supplied as a command line argu- ment), parse it, create a block-structured symbol table, type check the program, and emit an ASCII representation of the type expressions computed for each construct. We recommend instrumenting your parser from project 2 with semantic actions to construct a sequence of syntax trees and to dec- orate the nodes of those trees with type expressions. You may then traverse these trees in order to
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: emit the type expressions. If parsing and analysis are successful, your program should return 0. If the input contains errors, your program should output a meaningful error message, detailing the line number upon which the error was detected. Additional materials: Sample formats for the type expressions and error messages will be posted to the cse450 projects web site. In addition to the sample programs from Projects 1 and 2, we will place additional, type-incorrect samples in: /user/cse450/Public/Projects/P3/samples These programs (and others) will be used to evaluate your submission. Additional constraints: Your project will be graded on the CSE Suns, which means it must compile and build correctly on arctic. This project is due at 11:59pm Monday, March 10. 1...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online