Implement a parser for the CJ language using JavaCC.
Once you have this working you will then use your parser to construct an abstract syntax tree (AST) for the input program. We will provide Java classes to represent the abstract syntax trees in a week.
Before starting this project, familiarize yourself with Chapters 3 & 4 of the textbook. In addition to the lectures, this will give you a solid foundation for starting your parser.
You should turn in just your JavaCC file, which implements your parser, using the turnin command available on CS Unix machines.
We will create a set of test cases, and then compare the output of your solution to our reference implementation. Grading test cases are intended to test separable functionality of your parser.
There will be a reconciliation period after initial grading when you will be able to compare outputs of your parser with those of the reference implementation, and you may then offer simple fixes for the TAs to apply to your implementation to improve your grade. These fixes will be accepted only at the discretion of the TAs and the instructor (we will judge what "simple" means!)
The reconciliation period is only intended for you to be able to fix simple problems that you may have mistakenly overlooked. Thus, you must make sure to test your implementation thoroughly.