Bug 1434710 - Replaced mozilla::IndexSequence with std::index_sequence and removed #include "mozilla/IndexSequence.h" from js/src/threading/Thread.h. r=botond draft
authorTom Bannister <tomabann@gmail.com>
Wed, 04 Apr 2018 20:20:44 +1000
changeset 778304 988a0dc89b8869190615fd3ba2b61ea9165487b1
parent 778303 77c76f1108d6dacb118d282d692cf85515a28a0e
child 778305 ba4e878caca9f632537e1202046cac561757c95b
push id105466
push userbmo:tomabann@gmail.com
push dateFri, 06 Apr 2018 06:41:20 +0000
reviewersbotond
bugs1434710
milestone61.0a1
Bug 1434710 - Replaced mozilla::IndexSequence with std::index_sequence and removed #include "mozilla/IndexSequence.h" from js/src/threading/Thread.h. r=botond MozReview-Commit-ID: AXRmKV8PMVy
js/src/threading/Thread.h
--- a/js/src/threading/Thread.h
+++ b/js/src/threading/Thread.h
@@ -5,17 +5,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef threading_Thread_h
 #define threading_Thread_h
 
 #include "mozilla/Atomics.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/HashFunctions.h"
-#include "mozilla/IndexSequence.h"
 #include "mozilla/TimeStamp.h"
 #include "mozilla/Tuple.h"
 
 #include <stdint.h>
 
 #include "jsutil.h"
 
 #include "threading/LockGuard.h"
@@ -233,17 +232,17 @@ public:
   static THREAD_RETURN_TYPE THREAD_CALL_API Start(void* aPack) {
     auto* pack = static_cast<ThreadTrampoline<F, Args...>*>(aPack);
     pack->callMain(typename mozilla::IndexSequenceFor<Args...>::Type());
     js_delete(pack);
     return 0;
   }
 
   template<size_t ...Indices>
-  void callMain(mozilla::IndexSequence<Indices...>) {
+  void callMain(std::index_sequence<Indices...>) {
     f(mozilla::Get<Indices>(args)...);
   }
 };
 
 } // namespace detail
 } // namespace js
 
 #undef THREAD_RETURN_TYPE