What are the various error-recovery strategies

The various error-recovery strategies are

a) Panic mode – On discovering this error, the parser discards the input symbols one at a time until one of a designated set of synchronized tokens is found.
b) Phrase level – On discovering an error, a parser perform local correction on the remaining input ; that is , it may replace a prefix or the remaining input by some string that allows the parser to continue.
c) Error production and – If we are having good idea of error we recover it.
d) Global correction – Use the compiler to make as few changes as possible in processing an input string.

Leave a Reply