LemonJS/examples/calculator-js.out

103 lines
3.1 KiB
Plaintext
Raw Normal View History

2019-01-28 12:08:59 +00:00
State 0:
program ::= * expr
expr ::= * expr MINUS expr
expr ::= * expr PLUS expr
expr ::= * expr TIMES expr
expr ::= * expr DIVIDE expr
expr ::= * INTEGER
INTEGER shift-reduce 5 expr ::= INTEGER
program accept
expr shift 5
State 1:
expr ::= * expr MINUS expr
expr ::= * expr PLUS expr
expr ::= * expr TIMES expr
expr ::= * expr DIVIDE expr
expr ::= expr DIVIDE * expr
expr ::= * INTEGER
INTEGER shift-reduce 5 expr ::= INTEGER
expr shift-reduce 4 expr ::= expr DIVIDE expr
State 2:
expr ::= * expr MINUS expr
expr ::= * expr PLUS expr
expr ::= * expr TIMES expr
expr ::= expr TIMES * expr
expr ::= * expr DIVIDE expr
expr ::= * INTEGER
INTEGER shift-reduce 5 expr ::= INTEGER
expr shift-reduce 3 expr ::= expr TIMES expr
State 3:
expr ::= * expr MINUS expr
expr ::= * expr PLUS expr
expr ::= expr PLUS * expr
expr ::= * expr TIMES expr
expr ::= * expr DIVIDE expr
expr ::= * INTEGER
INTEGER shift-reduce 5 expr ::= INTEGER
expr shift 6
State 4:
expr ::= * expr MINUS expr
expr ::= expr MINUS * expr
expr ::= * expr PLUS expr
expr ::= * expr TIMES expr
expr ::= * expr DIVIDE expr
expr ::= * INTEGER
INTEGER shift-reduce 5 expr ::= INTEGER
expr shift 7
State 5:
(0) program ::= expr *
expr ::= expr * MINUS expr
expr ::= expr * PLUS expr
expr ::= expr * TIMES expr
expr ::= expr * DIVIDE expr
$ reduce 0 program ::= expr
PLUS shift 3
MINUS shift 4
DIVIDE shift 1
TIMES shift 2
State 6:
expr ::= expr * MINUS expr
expr ::= expr * PLUS expr
(2) expr ::= expr PLUS expr *
expr ::= expr * TIMES expr
expr ::= expr * DIVIDE expr
DIVIDE shift 1
TIMES shift 2
{default} reduce 2 expr ::= expr PLUS expr
State 7:
expr ::= expr * MINUS expr
(1) expr ::= expr MINUS expr *
expr ::= expr * PLUS expr
expr ::= expr * TIMES expr
expr ::= expr * DIVIDE expr
DIVIDE shift 1
TIMES shift 2
{default} reduce 1 expr ::= expr MINUS expr
----------------------------------------------------
Symbols:
0: $:
1: PLUS
2: MINUS
3: DIVIDE
4: TIMES
5: INTEGER
6: error:
7: program: INTEGER
8: expr: INTEGER