summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-extended/mozjs/mozjs-115/1894423.patch
blob: 93e0f0f4f9572ae0628f93eb0fbff9e2f193ee77 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Bug 1894423 - Remove unused ExclusiveData move constructor. r=spidermonkey-reviewers,jonco

Because the constructor is actually not used, the compiler used to not
complain about it being broken. Recent changes on clang trunk made it
catch this problem without the constructor being used.

As Mutex doesn't have a move constructor, it's also not only a matter of
adding the missing underscore to lock.

As the constructor is never used, just remove it.

Differential Revision: https://phabricator.services.mozilla.com/D209108

Upstream-Status: Backport [https://hg.mozilla.org/mozilla-central/rev/223087fdc29f]
Signed-off-by: Khem Raj <raj.khem@gmail.com>

--- a/js/src/threading/ExclusiveData.h
+++ b/js/src/threading/ExclusiveData.h
@@ -109,11 +109,6 @@ class ExclusiveData {
   explicit ExclusiveData(const MutexId& id, Args&&... args)
       : lock_(id), value_(std::forward<Args>(args)...) {}
 
-  ExclusiveData(ExclusiveData&& rhs)
-      : lock_(std::move(rhs.lock)), value_(std::move(rhs.value_)) {
-    MOZ_ASSERT(&rhs != this, "self-move disallowed!");
-  }
-
   ExclusiveData& operator=(ExclusiveData&& rhs) {
     this->~ExclusiveData();
     new (mozilla::KnownNotNull, this) ExclusiveData(std::move(rhs));