nsVoidArray classArray;
nsAutoVoidArray classArray;
CSSRuleProcessor::RulesMatching(nsIPresContext* aPresContext,                                nsIAtom* aMedium,                                 nsIContent* aContent,                                nsIStyleContext* aParentContext,                                nsISupportsArray* aResults){  NS_PRECONDITION(nsnull != aPresContext, "null arg");  NS_PRECONDITION(nsnull != aContent, "null arg");  NS_PRECONDITION(nsnull != aResults, "null arg");  RuleCascadeData* cascade = GetRuleCascade(aMedium);  if (cascade) {    ContentEnumData data(aPresContext, aContent, aParentContext, aResults);    nsIAtom* tagAtom;    aContent->GetTag(tagAtom);    nsIAtom* idAtom = nsnull;    nsVoidArray classArray; // XXX need to recycle this guy (or make nsAutoVoidArray?)    nsIStyledContent* styledContent;    if (NS_SUCCEEDED(aContent->QueryInterface(nsIStyledContent::GetIID(), (void**)&styledContent))) {      styledContent->GetID(idAtom);      styledContent->GetClasses(classArray);      NS_RELEASE(styledContent);    }    cascade->mRuleHash.EnumerateAllRules(tagAtom, idAtom, classArray, ContentEnumFunc, &data);#ifdef DEBUG_RULES    nsISupportsArray* list1;    nsISupportsArray* list2;    NS_NewISupportsArray(&list1);    NS_NewISupportsArray(&list2);    data.mResults = list1;    cascade->mRuleHash.EnumerateAllRules(tagAtom, idAtom, classArray, ContentEnumFunc, &data);    data.mResults = list2;    cascade->mWeightedRules->EnumerateBackwards(ContentEnumWrap, &data);    NS_ASSERTION(list1->Equals(list2), "lists not equal");    NS_RELEASE(list1);    NS_RELEASE(list2);#endif    NS_IF_RELEASE(tagAtom);    NS_IF_RELEASE(idAtom);  }  return NS_OK;}