The name of the class nsReferencedElement (and it's location in dom/base) makes it sound like it's an nsIContent sub-class. In fact there is no inheritance relationship between nsReferencedElement and nsIContent (or dom::Element). This is in fact just a helper class to keep track of which element is pointed to by a given ID in a document.