Bug 775624 Part 23 - Remove constructor and all operators related to uint32_t. r?dholbert draft
authorTing-Yu Lin <tlin@mozilla.com>
Tue, 14 Feb 2017 18:01:11 +0800
changeset 488098 5207acb68aafb488ba286b929a13a17a6c77c2fc
parent 488097 6b300105284474c10e89bc8de4b56accf8127be6
child 488099 723ac47a536ab7bf51853ee24e650edc5de43ae2
push id46419
push userbmo:tlin@mozilla.com
push dateWed, 22 Feb 2017 15:26:16 +0000
reviewersdholbert
bugs775624
milestone54.0a1
Bug 775624 Part 23 - Remove constructor and all operators related to uint32_t. r?dholbert MozReview-Commit-ID: FEVYMhcpPS0
layout/generic/nsIFrame.h
--- a/layout/generic/nsIFrame.h
+++ b/layout/generic/nsIFrame.h
@@ -196,18 +196,17 @@ enum nsSpread {
 
 //----------------------------------------------------------------------
 // Reflow status returned by the Reflow() methods.
 class nsReflowStatus final {
   using StyleClear = mozilla::StyleClear;
 
 public:
   nsReflowStatus()
-    : mStatus(0)
-    , mBreakType(StyleClear::None)
+    : mBreakType(StyleClear::None)
     , mIncomplete(false)
     , mOverflowIncomplete(false)
     , mNextInFlowNeedsReflow(false)
     , mTruncated(false)
     , mInlineBreak(false)
     , mInlineBreakAfter(false)
     , mFirstLetterComplete(false)
   {}
@@ -219,53 +218,16 @@ public:
     mOverflowIncomplete = false;
     mNextInFlowNeedsReflow = false;
     mTruncated = false;
     mInlineBreak = false;
     mInlineBreakAfter = false;
     mFirstLetterComplete = false;
   }
 
-  nsReflowStatus(uint32_t aStatus)
-    : mStatus(aStatus)
-  {}
-
-  uint32_t& operator=(uint32_t aRhs) {
-    mStatus = aRhs;
-    return mStatus;
-  }
-
-  uint32_t operator&(uint32_t aRhs) const {
-    return mStatus & aRhs;
-  }
-
-  uint32_t operator&=(uint32_t aRhs) {
-    return mStatus = mStatus & aRhs;
-  }
-
-  uint32_t operator|(uint32_t aRhs) const {
-    return mStatus | aRhs;
-  }
-
-  uint32_t operator|=(uint32_t aRhs) {
-    return mStatus = mStatus | aRhs;
-  }
-
-  uint32_t operator>>(uint32_t aRhs) const {
-    return mStatus >> aRhs;
-  }
-
-  bool operator==(uint32_t aRhs) const {
-    return mStatus == aRhs;
-  }
-
-  bool operator!=(uint32_t aRhs) const {
-    return !(*this == aRhs);
-  }
-
   // Return true if all flags are cleared.
   bool IsEmpty() const {
     return (!mIncomplete &&
             !mOverflowIncomplete &&
             !mNextInFlowNeedsReflow &&
             !mTruncated &&
             !mInlineBreak &&
             !mInlineBreakAfter &&
@@ -360,18 +322,16 @@ public:
   }
 
   // mFirstLetterComplete bit flag means the break was induced by
   // completion of a first-letter.
   bool FirstLetterComplete() const { return mFirstLetterComplete; }
   void SetFirstLetterComplete() { mFirstLetterComplete = true; }
 
 private:
-  uint32_t mStatus;
-
   StyleClear mBreakType;
 
   // Frame completion status bit flags.
   bool mIncomplete : 1;
   bool mOverflowIncomplete : 1;
   bool mNextInFlowNeedsReflow : 1;
   bool mTruncated : 1;