Contents
Page-10
Prev
Next
Page+10
Index
Parsing Techniques
Recursive Descent and Operator Precedence:
- Advantages:
- Easy to control, understand.
- Good error messages can be produced.
- Disadvantages:
- More code to write.
- Grammar not as clear.
Does the program really match the grammar?
Parser Generator: yacc
- Advantages:
- Less code to write.
- Grammar is clear and easy to change.
- Disadvantages:
- The programmer may get ``stuck'' on grammar errors that are hard
to understand.
- Error messages during compilation may be unhelpful and
far from the actual error.