Map of all FOLLOW-sets of a SLR syntax. Key is nonterminal.
The FIRST-set for a nonterminal is the collection of terminals that
appear on first position of the right side of all rules where that
nonterminal appears on the left side.
Algorithm:
Search all rules that contain the nonterminal on left side.
Scan the right side of all these rules until a terminal or a non-nullable
nonterminal appears. The terminal goes to FIRST, the FIRST sets of
all scanned nonterminals go to FIRST. This implies that one must
collect FIRST sets recursively, for every scanned nonterminal.
author: (c) 2000, Fritz Ritzberger |