In this process of
compilation the parser and lexical analyzer work together. That means, when
parser required string of tokens it invokes lexical analyzer .In turn, the
lexical analyzer supplies tokens to syntax analyzer (parser).
The parser collects sufficient number of
tokens and builds a parse tree. Then by building the parse tree, parse smartly
finds the syntactical errors if any. It is also necessary that the parse should
recover from commonly occurring errors so that remaining task of process the
input can be continued.
0 comments:
Post a Comment