- MetaGrammar.Production p = new MetaGrammar.Production(tag, nonTerminalName, els, drops);
- for(Method m : _allMethods)
+
+ String key = tag==null?nonTerminalName:tag;
+ if (key==null) return null;
+
+ String prefix = key.indexOf('.')==-1 ? "" : key.substring(0, key.lastIndexOf('.'));
+ String suffix = key.indexOf('.')==-1 ? key : key.substring(key.lastIndexOf('.')+1);
+
+ MetaGrammar.Production p = new MetaGrammar.Production(suffix, suffix, els, drops);
+ for(Method m : _allMethods.get(prefix))