Home

Research

Publications

Teaching

Project Proposals

Computing Home

DCU Home

 

CA448 - Compiler Construction 1

[ Intro ] [ Notes ] [ Exercises ] [ Assignments ] [ End of Year Exam ] [ Links ]

Lexical Analyser, Parser and Semantic Analyser for the Bantam Java Language

Aim

The aim of these assignments is to implement a lexical analyser, parser and semantic analyser for the base version of the Bantam Java language, as described here. The assignments must be implemented using JavaCC and are worth a total of 30% of the overall marks for this course. These are individual assignments. Submissions will be checked very closely for signs of plagiarism, for which the usual penalties apply.

Assignment 1: The Lexical Analyser (10%)

For this assignment, you should implement a lexical analyser for the base version of the Bantam Java language, as described in Project 1 in the manual.

You should test the lexical analyser thoroughly before moving on to the next assignment.

Submission

You should submit all the source files (JavaCC file and other files which were used to generate your lexical analyser) along with a brief description of each of the major components of your lexical analyser describing how you implemented them and justifying why you implemented them in the way you did, by 9am on Monday 9th November.

Marks

Assignment 2: The Syntax Analyser (20%)

For this assignment, you should implement a syntax analyser for the base version of the Bantam Java language, as described in Project 2 in the manual.

Submission

You should submit all the source files (JavaCC file and other files which were used to generate your syntax analyser) along with a brief description of each of the major components of your syntax analyser describing how you implemented them and justifying why you implemented them in the way you did, by 5pm on Friday 18th December.

Marks