child->mNext = (CSSStyleSheetImpl*)aSheet;
((CSSStyleSheetImpl*)child)->mNext.SetAddRef(aSheet);
void CSSStyleSheetImpl::AppendStyleSheet(nsICSSStyleSheet* aSheet){  NS_PRECONDITION(nsnull != aSheet, "null arg");  if (nsnull == mFirstChild) {    mFirstChild = (CSSStyleSheetImpl*)aSheet;  }  else {    CSSStyleSheetImpl* child = mFirstChild;    while (nsnull != child->mNext) {      child = child->mNext;    }    child->mNext = (CSSStyleSheetImpl*)aSheet;  }  NS_ADDREF(aSheet);}