Bug 1156802 - Part 2: Remove all explicit move constructors, r=ehsan
authorMichael Layzell <michael@thelayzells.com>
Thu, 03 Sep 2015 10:51:42 -0400
changeset 294773 c1cdde5ccb2ce94790fd7f6f7dfd0f21d69cf72d
parent 294772 63f3a49b15cbce9c99a4ba7f8fce2602dfc0b3ed
child 294774 2cbbc360ec41d01937e41c5f264fea40032535e1
push id5245
push userraliiev@mozilla.com
push dateThu, 29 Oct 2015 11:30:51 +0000
treeherdermozilla-beta@dac831dc1bd0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersehsan
bugs1156802
milestone43.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1156802 - Part 2: Remove all explicit move constructors, r=ehsan
dom/base/URLSearchParams.h
dom/bindings/Nullable.h
dom/bindings/TypedArray.h
dom/indexedDB/ActorsChild.h
js/src/jsscript.h
mfbt/Scoped.h
xpcom/glue/nsTArray.h
--- a/dom/base/URLSearchParams.h
+++ b/dom/base/URLSearchParams.h
@@ -40,17 +40,17 @@ public:
   {
     DeleteAll();
   }
 
   explicit URLParams(const URLParams& aOther)
     : mParams(aOther.mParams)
   {}
 
-  explicit URLParams(const URLParams&& aOther)
+  URLParams(const URLParams&& aOther)
     : mParams(Move(aOther.mParams))
   {}
 
   class ForEachIterator
   {
   public:
     virtual bool
     URLParamsIterator(const nsString& aName, const nsString& aValue) = 0;
--- a/dom/bindings/Nullable.h
+++ b/dom/bindings/Nullable.h
@@ -30,17 +30,17 @@ public:
   {}
 
   explicit Nullable(T aValue)
     : mValue()
   {
     mValue.emplace(aValue);
   }
 
-  explicit Nullable(Nullable<T>&& aOther)
+  Nullable(Nullable<T>&& aOther)
     : mValue(mozilla::Move(aOther.mValue))
   {}
 
   Nullable(const Nullable<T>& aOther)
     : mValue(aOther.mValue)
   {}
 
   void operator=(const Nullable<T>& aOther)
--- a/dom/bindings/TypedArray.h
+++ b/dom/bindings/TypedArray.h
@@ -28,17 +28,17 @@ protected:
   JSObject* mWrappedObj;
 
   TypedArrayObjectStorage()
     : mTypedObj(nullptr),
       mWrappedObj(nullptr)
   {
   }
 
-  explicit TypedArrayObjectStorage(TypedArrayObjectStorage&& aOther)
+  TypedArrayObjectStorage(TypedArrayObjectStorage&& aOther)
     : mTypedObj(aOther.mTypedObj),
       mWrappedObj(aOther.mWrappedObj)
   {
     aOther.mTypedObj = nullptr;
     aOther.mWrappedObj = nullptr;
   }
 
 public:
@@ -70,17 +70,17 @@ struct TypedArray_base : public TypedArr
 
   TypedArray_base()
     : mData(nullptr),
       mLength(0),
       mComputed(false)
   {
   }
 
-  explicit TypedArray_base(TypedArray_base&& aOther)
+  TypedArray_base(TypedArray_base&& aOther)
     : TypedArrayObjectStorage(Move(aOther)),
       mData(aOther.mData),
       mLength(aOther.mLength),
       mComputed(aOther.mComputed)
   {
     aOther.mData = nullptr;
     aOther.mLength = 0;
     aOther.mComputed = false;
@@ -145,17 +145,17 @@ struct TypedArray : public TypedArray_ba
 private:
   typedef TypedArray_base<T, UnwrapArray, GetLengthAndData> Base;
 
 public:
   TypedArray()
     : Base()
   {}
 
-  explicit TypedArray(TypedArray&& aOther)
+  TypedArray(TypedArray&& aOther)
     : Base(Move(aOther))
   {
   }
 
   static inline JSObject*
   Create(JSContext* cx, nsWrapperCache* creator, uint32_t length,
          const T* data = nullptr) {
     JS::Rooted<JSObject*> creatorWrapper(cx);
@@ -199,17 +199,17 @@ private:
   typedef TypedArray_base<uint8_t, UnwrapArray, GetLengthAndData> Base;
 
 public:
   ArrayBufferView_base()
     : Base()
   {
   }
 
-  explicit ArrayBufferView_base(ArrayBufferView_base&& aOther)
+  ArrayBufferView_base(ArrayBufferView_base&& aOther)
     : Base(Move(aOther)),
       mType(aOther.mType)
   {
     aOther.mType = js::Scalar::MaxTypedArrayViewType;
   }
 
 private:
   js::Scalar::Type mType;
--- a/dom/indexedDB/ActorsChild.h
+++ b/dom/indexedDB/ActorsChild.h
@@ -700,17 +700,17 @@ class BackgroundCursorChild final
   friend class BackgroundVersionChangeTransactionChild;
 
   class DelayedActionRunnable;
 
   struct CachedResponse
   {
     CachedResponse();
 
-    explicit CachedResponse(CachedResponse&& aOther);
+    CachedResponse(CachedResponse&& aOther);
 
     Key mKey;
     Key mObjectKey;
     StructuredCloneReadInfo mCloneInfo;
   };
 
   IDBRequest* mRequest;
   IDBTransaction* mTransaction;
--- a/js/src/jsscript.h
+++ b/js/src/jsscript.h
@@ -450,17 +450,17 @@ class MutableHandleBase<Bindings>
 
 class ScriptCounts
 {
   public:
     typedef mozilla::Vector<PCCounts, 0, SystemAllocPolicy> PCCountsVector;
 
     inline ScriptCounts();
     inline explicit ScriptCounts(PCCountsVector&& jumpTargets);
-    inline explicit ScriptCounts(ScriptCounts&& src);
+    inline ScriptCounts(ScriptCounts&& src);
     inline ~ScriptCounts();
 
     inline ScriptCounts& operator=(ScriptCounts&& src);
 
     // Return the counter used to count the number of visits. Returns null if
     // the element is not found.
     PCCounts* maybeGetPCCounts(size_t offset);
     const PCCounts* maybeGetPCCounts(size_t offset) const;
@@ -2358,17 +2358,17 @@ FreeScriptData(JSRuntime* rt);
 
 struct ScriptAndCounts
 {
     /* This structure is stored and marked from the JSRuntime. */
     JSScript* script;
     ScriptCounts scriptCounts;
 
     inline explicit ScriptAndCounts(JSScript* script);
-    inline explicit ScriptAndCounts(ScriptAndCounts&& sac);
+    inline ScriptAndCounts(ScriptAndCounts&& sac);
 
     const PCCounts* maybeGetPCCounts(jsbytecode* pc) const {
         return scriptCounts.maybeGetPCCounts(script->pcToOffset(pc));
     }
     const PCCounts* maybeGetThrowCounts(jsbytecode* pc) const {
         return scriptCounts.maybeGetThrowCounts(script->pcToOffset(pc));
     }
 
--- a/mfbt/Scoped.h
+++ b/mfbt/Scoped.h
@@ -91,18 +91,18 @@ public:
   explicit Scoped(const Resource& aValue
                   MOZ_GUARD_OBJECT_NOTIFIER_PARAM)
     : mValue(aValue)
   {
     MOZ_GUARD_OBJECT_NOTIFIER_INIT;
   }
 
   /* Move constructor. */
-  explicit Scoped(Scoped&& aOther
-                  MOZ_GUARD_OBJECT_NOTIFIER_PARAM)
+  Scoped(Scoped&& aOther
+         MOZ_GUARD_OBJECT_NOTIFIER_PARAM)
     : mValue(Move(aOther.mValue))
   {
     MOZ_GUARD_OBJECT_NOTIFIER_INIT;
     aOther.mValue = Traits::empty();
   }
 
   ~Scoped() { Traits::release(mValue); }
 
@@ -204,18 +204,18 @@ struct name : public mozilla::Scoped<Tra
   explicit name(MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM)                         \
     : Super(MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM_TO_PARENT)                   \
   {}                                                                          \
   explicit name(Resource aRhs                                                 \
                 MOZ_GUARD_OBJECT_NOTIFIER_PARAM)                              \
     : Super(aRhs                                                              \
             MOZ_GUARD_OBJECT_NOTIFIER_PARAM_TO_PARENT)                        \
   {}                                                                          \
-  explicit name(name&& aRhs                                                   \
-                MOZ_GUARD_OBJECT_NOTIFIER_PARAM)                              \
+  name(name&& aRhs                                                            \
+       MOZ_GUARD_OBJECT_NOTIFIER_PARAM)                                       \
     : Super(Move(aRhs)                                                        \
             MOZ_GUARD_OBJECT_NOTIFIER_PARAM_TO_PARENT)                        \
   {}                                                                          \
 private:                                                                      \
   explicit name(name&) = delete;                                              \
   name& operator=(name&) = delete;                                            \
 };
 
--- a/xpcom/glue/nsTArray.h
+++ b/xpcom/glue/nsTArray.h
@@ -2138,17 +2138,17 @@ class FallibleTArray : public nsTArray_I
 public:
   typedef nsTArray_Impl<E, nsTArrayFallibleAllocator>   base_type;
   typedef FallibleTArray<E>                             self_type;
   typedef typename base_type::size_type                 size_type;
 
   FallibleTArray() {}
   explicit FallibleTArray(size_type aCapacity) : base_type(aCapacity) {}
   explicit FallibleTArray(const FallibleTArray<E>& aOther) : base_type(aOther) {}
-  explicit FallibleTArray(FallibleTArray<E>&& aOther)
+  FallibleTArray(FallibleTArray<E>&& aOther)
     : base_type(mozilla::Move(aOther))
   {
   }
 
   template<class Allocator>
   explicit FallibleTArray(const nsTArray_Impl<E, Allocator>& aOther)
     : base_type(aOther)
   {