var = aThis->mRules.LookupSymbol(PromiseFlatString(aVariable).get());
var = c->match.mRule->LookupSymbol(aVariable);
nsXULTemplateBuilder::SubstituteTextReplaceVariable(nsXULTemplateBuilder* aThis,                                                    const nsAString& aVariable,                                                    void* aClosure){    // Substitute the value for the variable and append to the    // closure's result.    SubstituteTextClosure* c = NS_STATIC_CAST(SubstituteTextClosure*, aClosure);    // The symbol "rdf:*" is special, and means "this guy's URI"    PRInt32 var = 0;    if (aVariable.EqualsLiteral("rdf:*"))        var = c->match.mRule->GetMemberVariable();    else        var = aThis->mRules.LookupSymbol(PromiseFlatString(aVariable).get());    // No variable; treat as a variable with no substitution. (This    // shouldn't ever happen, really...)    if (! var)        return;    // Got a variable; get the value it's assigned to    Value value;    PRBool hasAssignment =        c->match.GetAssignmentFor(aThis->mConflictSet, var, &value);    // If there was no assignment for the variable, bail. This'll    // leave the result string with an empty substitution for the    // variable.    if (! hasAssignment)        return;    // Got a value; substitute it.    switch (value.GetType()) {    case Value::eISupports:        {            nsISupports* isupports = NS_STATIC_CAST(nsISupports*, value);            nsCOMPtr<nsIRDFNode> node = do_QueryInterface(isupports);            if (node) {                // XXX ideally we'd just point this right at the                // substring which is the end of the string,                // turning this into an in-place append.                nsAutoString temp;                nsXULContentUtils::GetTextForNode(node, temp);                c->result += temp;            }        }    break;    case Value::eString:        c->result += NS_STATIC_CAST(const PRUnichar*, value);        break;    default:        break;    }    }