Correct comment describing nsRuleData::ValueFor. (Bug 636039, patch 2) r=bzbarsky
authorL. David Baron <dbaron@dbaron.org>
Thu, 17 Mar 2011 20:14:30 -0700
changeset 63737 7f5df6fc73df61f0a1b9e2c963176708be9a4822
parent 63736 61ce3fc46a8286583bce2b80610642a44efe4d13
child 63738 a23bc9d24c26ff5edf0571d3b9a9b426e8489f7b
push idunknown
push userunknown
push dateunknown
reviewersbzbarsky
bugs636039
milestone2.0b13pre
Correct comment describing nsRuleData::ValueFor. (Bug 636039, patch 2) r=bzbarsky nsRuleData::ValueFor does not return null; it checks conditions that would cause it to do so with NS_ABORT_IF_FALSE. Callers are required to check mSIDs.
layout/style/nsRuleData.h
--- a/layout/style/nsRuleData.h
+++ b/layout/style/nsRuleData.h
@@ -100,15 +100,17 @@ struct nsRuleData
       mXULData(nsnull),
       mSVGData(nsnull),
       mColumnData(nsnull)
   {}
   ~nsRuleData() {}
 
   /**
    * Return a pointer to the value object within |this| corresponding
-   * to property |aProperty|, or null if storage for that property has
-   * not been allocated.
+   * to property |aProperty|.
+   *
+   * This function must only be called if the given property is in
+   * mSIDs.
    */
   nsCSSValue* ValueFor(nsCSSProperty aProperty);
 };
 
 #endif