protected void closure(Syntax syntax)	{
		// put Hashtable to List for sequential work
		List todo = new ArrayList(entries.size() * 2);
		for (Enumeration e = entries.elements(); e.hasMoreElements(); )
			todo.add(e.nextElement());

		// loop todo list and find every added new item
		for (int i = 0; i < todo.size(); i++)	{
			RuleStateItem rsi = (RuleStateItem)todo.get(i);
			String nonterm = rsi.getPendingNonTerminal();
			if (nonterm != null)
				addRulesDerivingPendingNonTerminal(rsi, nonterm, syntax, todo);
		}
	}