Project #2 Coffee Language Parse solution


Original Work


5/5 - (1 vote)

Coffee Language Parse (100 points): Given the previous description of the Coffee language
(CoffeLanguage_Syntax.pdf) you are asked to implement the parser. You are expected to use ShiftReduce
parser. Your output will be the string representation of a parse tree. Tokenization should be
done by your previous project. You should implement your own tree structure to build your parse tree.
You will combine your previous project with the code provided and complete the Parser class.
The only file that you are required to modify is “” and “”.
Submission and Grading contains an IntelliJ Idea project, you are expected to submit an IntelliJ Idea project.
Do not modify the provided files other than Parser and Lexer classes.
Example input:
(+ x y)
Parsing result:

– (+ EXPI Id)
– (+ Id Id)
Note: There are several changes in Coffee Project. You should consider these changes and modify your
Project 1 submission according to new version.