Bug 1259878 - remove unnecessary isSome(). r=birtles
authorHiroyuki Ikezoe <hiikezoe@mozilla-japan.org>
Sat, 26 Mar 2016 10:52:08 +0900
changeset 290549 3a90ca63a3f04c0b84200e9d3b0a806dd93453fa
parent 290548 1fc001760e73deabb9c2114bd88876be3699a0b8
child 290550 f3d7946a5cb969f875790b8685092b841985d320
push id19656
push usergwagner@mozilla.com
push dateMon, 04 Apr 2016 13:43:23 +0000
treeherderb2g-inbound@e99061fde28a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbirtles
bugs1259878
milestone48.0a1
Bug 1259878 - remove unnecessary isSome(). r=birtles MozReview-Commit-ID: 3Xh2D5TOTSg
dom/animation/AnimationEffectTimingReadOnly.cpp
dom/animation/ComputedTimingFunction.h
--- a/dom/animation/AnimationEffectTimingReadOnly.cpp
+++ b/dom/animation/AnimationEffectTimingReadOnly.cpp
@@ -35,17 +35,17 @@ AnimationEffectTimingReadOnly::GetDurati
   } else {
     aRetVal.SetAsString().AssignLiteral("auto");
   }
 }
 
 void
 AnimationEffectTimingReadOnly::GetEasing(nsString& aRetVal) const
 {
-  if (mTiming.mFunction.isSome()) {
+  if (mTiming.mFunction) {
     mTiming.mFunction->AppendToString(aRetVal);
   } else {
     aRetVal.AssignLiteral("linear");
   }
 }
 
 } // namespace dom
 } // namespace mozilla
--- a/dom/animation/ComputedTimingFunction.h
+++ b/dom/animation/ComputedTimingFunction.h
@@ -39,17 +39,17 @@ public:
     return !(*this == aOther);
   }
   int32_t Compare(const ComputedTimingFunction& aRhs) const;
   void AppendToString(nsAString& aResult) const;
 
   static double GetPortion(const Maybe<ComputedTimingFunction>& aFunction,
                            double aPortion)
   {
-    return aFunction.isSome() ? aFunction->GetValue(aPortion) : aPortion;
+    return aFunction ? aFunction->GetValue(aPortion) : aPortion;
   }
   static int32_t Compare(const Maybe<ComputedTimingFunction>& aLhs,
                          const Maybe<ComputedTimingFunction>& aRhs);
 
 private:
   nsTimingFunction::Type mType;
   nsSMILKeySpline mTimingFunction;
   uint32_t mSteps;