Chapter 4: Syntax Analysis

Shift reduce parsing

. Split string being parsed into two parts

- Two parts are separated by a special character "."

- Left part is a string of terminals and non terminals

- Right part is a string of terminals

. Initially the input is .w

A convenient way to implement a shift reduce parser is by using an input buffer to hold the string w to be parsed. At any stage, the input string is split into two parts which are separated by the character ' . '. The left part consists of terminals and non-terminals while the right part consists of terminals only. Initially, the string " .w " is on the input.