Conflict in state 21 between rule 17 and token '+' resolved as reduce.
Conflict in state 21 between rule 17 and token '-' resolved as reduce.
Conflict in state 21 between rule 17 and token '*' resolved as reduce.
Conflict in state 21 between rule 17 and token '/' resolved as reduce.
Conflict in state 21 between rule 17 and token POWOP resolved as reduce.
Conflict in state 21 between rule 17 and token '?' resolved as shift.
Conflict in state 21 between rule 17 and token ',' resolved as shift.
Conflict in state 23 between rule 7 and token '+' resolved as reduce.
Conflict in state 23 between rule 7 and token '-' resolved as reduce.
Conflict in state 23 between rule 7 and token '*' resolved as shift.
Conflict in state 23 between rule 7 and token '/' resolved as shift.
Conflict in state 23 between rule 7 and token POWOP resolved as shift.
Conflict in state 23 between rule 7 and token '?' resolved as shift.
Conflict in state 23 between rule 7 and token ',' resolved as shift.
Conflict in state 24 between rule 8 and token '+' resolved as reduce.
Conflict in state 24 between rule 8 and token '-' resolved as reduce.
Conflict in state 24 between rule 8 and token '*' resolved as shift.
Conflict in state 24 between rule 8 and token '/' resolved as shift.
Conflict in state 24 between rule 8 and token POWOP resolved as shift.
Conflict in state 24 between rule 8 and token '?' resolved as shift.
Conflict in state 24 between rule 8 and token ',' resolved as shift.
Conflict in state 25 between rule 9 and token '+' resolved as reduce.
Conflict in state 25 between rule 9 and token '-' resolved as reduce.
Conflict in state 25 between rule 9 and token '*' resolved as reduce.
Conflict in state 25 between rule 9 and token '/' resolved as reduce.
Conflict in state 25 between rule 9 and token POWOP resolved as shift.
Conflict in state 25 between rule 9 and token '?' resolved as shift.
Conflict in state 25 between rule 9 and token ',' resolved as shift.
Conflict in state 26 between rule 10 and token '+' resolved as reduce.
Conflict in state 26 between rule 10 and token '-' resolved as reduce.
Conflict in state 26 between rule 10 and token '*' resolved as reduce.
Conflict in state 26 between rule 10 and token '/' resolved as reduce.
Conflict in state 26 between rule 10 and token POWOP resolved as shift.
Conflict in state 26 between rule 10 and token '?' resolved as shift.
Conflict in state 26 between rule 10 and token ',' resolved as shift.
Conflict in state 27 between rule 11 and token '+' resolved as reduce.
Conflict in state 27 between rule 11 and token '-' resolved as reduce.
Conflict in state 27 between rule 11 and token '*' resolved as reduce.
Conflict in state 27 between rule 11 and token '/' resolved as reduce.
Conflict in state 27 between rule 11 and token POWOP resolved as shift.
Conflict in state 27 between rule 11 and token '?' resolved as shift.
Conflict in state 27 between rule 11 and token ',' resolved as shift.
Conflict in state 29 between rule 13 and token '+' resolved as reduce.
Conflict in state 29 between rule 13 and token '-' resolved as reduce.
Conflict in state 29 between rule 13 and token '*' resolved as reduce.
Conflict in state 29 between rule 13 and token '/' resolved as reduce.
Conflict in state 29 between rule 13 and token POWOP resolved as reduce.
Conflict in state 29 between rule 13 and token '?' resolved as reduce.
Conflict in state 29 between rule 13 and token ',' resolved as reduce.
Conflict in state 31 between rule 12 and token '+' resolved as reduce.
Conflict in state 31 between rule 12 and token '-' resolved as reduce.
Conflict in state 31 between rule 12 and token '*' resolved as reduce.
Conflict in state 31 between rule 12 and token '/' resolved as reduce.
Conflict in state 31 between rule 12 and token POWOP resolved as reduce.
Conflict in state 31 between rule 12 and token '?' resolved as shift.
Conflict in state 31 between rule 12 and token ',' resolved as shift.
State 7 contains 1 shift/reduce conflict.
Grammar
rule 1 computation -> statement computation
rule 2 computation -> /* empty */
rule 3 statement -> expr ';'
rule 4 statement -> assignment ';'
rule 5 statement -> ';'
rule 6 expr -> '(' expr ')'
rule 7 expr -> expr '+' expr
rule 8 expr -> expr '-' expr
rule 9 expr -> expr '*' expr
rule 10 expr -> expr '/' expr
rule 11 expr -> expr POWOP expr
rule 12 expr -> expr '?' expr ':' expr
rule 13 expr -> expr ',' expr
rule 14 expr -> assignment
rule 15 expr -> NAME
rule 16 expr -> NUMBER
rule 17 assignment -> NAME ASSIGNOP expr
Terminals, with rules where they appear
$ (-1)
'(' (40) 6
')' (41) 6
'*' (42) 9
'+' (43) 7
',' (44) 13
'-' (45) 8
'/' (47) 10
':' (58) 12
';' (59) 3 4 5
'?' (63) 12
error (256)
NAME (258) 15 17
NUMBER (259) 16
POWOP (260) 11
ASSIGNOP (261) 17
Nonterminals, with rules where they appear
computation (17)
on left: 1 2, on right: 1
statement (18)
on left: 3 4 5, on right: 1
expr (19)
on left: 6 7 8 9 10 11 12 13 14 15 16, on right: 3 6 7 8 9 10 11
12 13 17
assignment (20)
on left: 17, on right: 4 14
state 0
NAME shift, and go to state 1
NUMBER shift, and go to state 2
';' shift, and go to state 3
'(' shift, and go to state 4
$default reduce using rule 2 (computation)
computation go to state 32
statement go to state 5
expr go to state 6
assignment go to state 7
state 1
expr -> NAME . (rule 15)
assignment -> NAME . ASSIGNOP expr (rule 17)
ASSIGNOP shift, and go to state 8
$default reduce using rule 15 (expr)
state 2
expr -> NUMBER . (rule 16)
$default reduce using rule 16 (expr)
state 3
statement -> ';' . (rule 5)
$default reduce using rule 5 (statement)
state 4
expr -> '(' . expr ')' (rule 6)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 9
assignment go to state 10
state 5
computation -> statement . computation (rule 1)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
';' shift, and go to state 3
'(' shift, and go to state 4
$default reduce using rule 2 (computation)
computation go to state 11
statement go to state 5
expr go to state 6
assignment go to state 7
state 6
statement -> expr . ';' (rule 3)
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
'+' shift, and go to state 12
'-' shift, and go to state 13
'*' shift, and go to state 14
'/' shift, and go to state 15
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
';' shift, and go to state 19
state 7
statement -> assignment . ';' (rule 4)
expr -> assignment . (rule 14)
';' shift, and go to state 20
';' [reduce using rule 14 (expr)]
$default reduce using rule 14 (expr)
state 8
assignment -> NAME ASSIGNOP . expr (rule 17)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 21
assignment go to state 10
state 9
expr -> '(' expr . ')' (rule 6)
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
'+' shift, and go to state 12
'-' shift, and go to state 13
'*' shift, and go to state 14
'/' shift, and go to state 15
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
')' shift, and go to state 22
state 10
expr -> assignment . (rule 14)
$default reduce using rule 14 (expr)
state 11
computation -> statement computation . (rule 1)
$default reduce using rule 1 (computation)
state 12
expr -> expr '+' . expr (rule 7)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 23
assignment go to state 10
state 13
expr -> expr '-' . expr (rule 8)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 24
assignment go to state 10
state 14
expr -> expr '*' . expr (rule 9)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 25
assignment go to state 10
state 15
expr -> expr '/' . expr (rule 10)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 26
assignment go to state 10
state 16
expr -> expr POWOP . expr (rule 11)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 27
assignment go to state 10
state 17
expr -> expr '?' . expr ':' expr (rule 12)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 28
assignment go to state 10
state 18
expr -> expr ',' . expr (rule 13)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 29
assignment go to state 10
state 19
statement -> expr ';' . (rule 3)
$default reduce using rule 3 (statement)
state 20
statement -> assignment ';' . (rule 4)
$default reduce using rule 4 (statement)
state 21
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
assignment -> NAME ASSIGNOP expr . (rule 17)
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 17 (assignment)
state 22
expr -> '(' expr ')' . (rule 6)
$default reduce using rule 6 (expr)
state 23
expr -> expr . '+' expr (rule 7)
expr -> expr '+' expr . (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
'*' shift, and go to state 14
'/' shift, and go to state 15
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 7 (expr)
state 24
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr '-' expr . (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
'*' shift, and go to state 14
'/' shift, and go to state 15
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 8 (expr)
state 25
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr '*' expr . (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 9 (expr)
state 26
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr '/' expr . (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 10 (expr)
state 27
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr POWOP expr . (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
POWOP shift, and go to state 16
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 11 (expr)
state 28
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr '?' expr . ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
'+' shift, and go to state 12
'-' shift, and go to state 13
'*' shift, and go to state 14
'/' shift, and go to state 15
POWOP shift, and go to state 16
'?' shift, and go to state 17
':' shift, and go to state 30
',' shift, and go to state 18
state 29
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr . ',' expr (rule 13)
expr -> expr ',' expr . (rule 13)
$default reduce using rule 13 (expr)
state 30
expr -> expr '?' expr ':' . expr (rule 12)
NAME shift, and go to state 1
NUMBER shift, and go to state 2
'(' shift, and go to state 4
expr go to state 31
assignment go to state 10
state 31
expr -> expr . '+' expr (rule 7)
expr -> expr . '-' expr (rule 8)
expr -> expr . '*' expr (rule 9)
expr -> expr . '/' expr (rule 10)
expr -> expr . POWOP expr (rule 11)
expr -> expr . '?' expr ':' expr (rule 12)
expr -> expr '?' expr ':' expr . (rule 12)
expr -> expr . ',' expr (rule 13)
'?' shift, and go to state 17
',' shift, and go to state 18
$default reduce using rule 12 (expr)
state 32
$ go to state 33
state 33
$ go to state 34
state 34
$default accept