I have attached my code in a file and also the grammar which I should follow, I am not really sure that I handle the errors correctly can someone help me to point out where I should work it out again? I am just not sure about the error recovery... handling the syntax error only...
Several things that I am asking you to do/suggest me to do in order to modify the code as minim as possible so that it can:
1. Print an error if a dcl is missing a semicolon and then continue parsing in the normal state
2. Print an error if an unknown type is detected, ie: float, boolean, which is not supported by the rule and then continue
to parse back in the normal state
3. Other errors, such as return statement without semicolon, errors in for loops, expression