Enum lalr::LR1Conflict
[−]
[src]
pub enum LR1Conflict<'a, T: 'a, N: 'a, A: 'a> { ReduceReduce { state: ItemSet<'a, T, N, A>, token: Option<&'a T>, r1: (&'a N, &'a Rhs<T, N, A>), r2: (&'a N, &'a Rhs<T, N, A>), }, ShiftReduce { state: ItemSet<'a, T, N, A>, token: Option<&'a T>, rule: (&'a N, &'a Rhs<T, N, A>), }, }
A conflict detected while trying to construct an LR(1) parse table.
Variants
ReduceReduce
A reduce-reduce conflict.
Fields of ReduceReduce
state: ItemSet<'a, T, N, A> | The LR(0) state in which the conflict occurs. |
token: Option<&'a T> | The token leading to the conflict, or |
r1: (&'a N, &'a Rhs<T, N, A>) | The first conflicting rule. |
r2: (&'a N, &'a Rhs<T, N, A>) | The second conflicting rule. |
ShiftReduce
A shift-reduce conflict.
Fields of ShiftReduce
state: ItemSet<'a, T, N, A> | The LR(0) state in which the conflict appears. |
token: Option<&'a T> | The token leading to the conflict, or |
rule: (&'a N, &'a Rhs<T, N, A>) | The reduce rule involved in the conflict. |