AMBIGUITY. The context-free grammar G = (VT, VN, S, P) is
L = {w | ( | w = | w) or ( | w = | w)}. | (17) |
|
(18) |
w = E E S S | (19) |
stmt | matched-stmt | unmatched-stmt | |
matched-stmt | if expr then matched-stmt else matched-stmt | |
matched-stmt | non-alternative-stmt | |
unmatched-stmt | if expr then stmt | |
unmatched-stmt | if expr then matched-stmt else unmatched-stmt |