public Object repeatTag() { return new Tree.ArrayBuildingTreeFunctor<Object>(); }
- public Sequence tryResolveTag(String tag, String nonTerminalName, Element[] els, Object[] labels, boolean[] drops) {
- MetaGrammar.Production p = new MetaGrammar.Production(tag, nonTerminalName, els, labels, drops);
+ public Sequence tryResolveTag(String tag, String nonTerminalName, Element[] els, boolean[] drops) {
+ MetaGrammar.Production p = new MetaGrammar.Production(tag, nonTerminalName, els, drops);
for(Method m : _allMethods)
if (new MetaGrammar.Target(m).isCompatible(p))
return new MetaGrammar.Target(m).makeSequence(p);
return new MetaGrammar.Target(c).makeSequence(p);
return null;
}
- public Sequence resolveTag(String tag, String nonTerminalName, Element[] els, Object[] labels, boolean[] drops) {
- MetaGrammar.Production p = new MetaGrammar.Production(tag, nonTerminalName, els, labels, drops);
- Sequence ret = tryResolveTag(tag, nonTerminalName, els, labels, drops);
+ public Sequence resolveTag(String tag, String nonTerminalName, Element[] els, boolean[] drops) {
+ MetaGrammar.Production p = new MetaGrammar.Production(tag, nonTerminalName, els, drops);
+ Sequence ret = tryResolveTag(tag, nonTerminalName, els, drops);
if (ret != null) return ret;
String message = "could not find a Java method/class/ctor matching tag \""+tag+
"\", nonterminal \""+nonTerminalName+"\" with " + els.length + " arguments";
if (harsh) {
throw new RuntimeException(message);
} else {
- return Sequence.rewritingSequence(tag, els, labels, drops);
+ return Sequence.rewritingSequence(tag, els, drops);
}
}