Walk.Follow wf = new Walk.Follow(top.empty(), p.owner(), all_elements, cache);
Reduction red = new Reduction(p);
state.reductions.put(wf.walk(p.owner()), red);
- if (wf.includesEof()) state.eofReductions.add(red, true);
+ if (wf.includesEof()) state.eofReductions.add(red);
}
// if the element following this position is an atom, copy the corresponding
}
*/
- public final int idx = master_state_idx++;
+ public final int idx = master_state_idx++;
private final HashSet<Position> hs;
private transient HashMap<Element,State> gotoSetNonTerminals = new HashMap<Element,State>();
private transient TopologicalBag<Token,State> gotoSetTerminals = new TopologicalBag<Token,State>();
private TopologicalBag<Token,Reduction> reductions = new TopologicalBag<Token,Reduction>();
- private FastSet<Reduction> eofReductions = new FastSet<Reduction>();
+ private HashSet<Reduction> eofReductions = new HashSet<Reduction>();
private TopologicalBag<Token,State> shifts = new TopologicalBag<Token,State>();
private boolean accept = false;
holder[numPop-1] = f;
return reduce(parent, numPop-2, rex, onlychild, target);
}
- public Forest reduce(GSS.Phase.Node parent, GSS.Phase.Node onlychild, GSS.Phase target, Forest rex) {
- return reduce(parent, numPop-1, rex, onlychild, target);
+ public Forest reduce(GSS.Phase.Node parent, GSS.Phase.Node onlychild, Forest rex) {
+ return reduce(parent, numPop-1, rex, onlychild, parent.phase());
}
private Forest zero = null;
} else {
State state = parent.state.gotoSetNonTerminals.get(position.owner());
if (state!=null)
- target.newNode(parent, rex, state, numPop<=0, parent.phase);
+ target.newNode(parent, rex, state, numPop<=0, parent.phase());
}
return rex;
}