private void makeReferences() {
        for (Iterator<ProductionRule> i = ruleIterator(); i.hasNext(); ) {
            ProductionRule rule = i.next();
            rule.makeReferences(this);
        }
        for (Iterator<NamedCondition> i = conditionIterator(); i.hasNext(); ) {
            NamedCondition namedCondition = i.next();
            namedCondition.getCondition().makeReferences(this);
        }
    }
Analyzes a query over this rule base

@param query the query to analyze
@param traceLevel the level of tracing to add to the query
@return the error caused by analyzing the query, or null if there was no error
        If there is an error, this query is destroyed (unusable)
container-search/src/main/java/com/yahoo/prelude/semantics/RuleBase.java