Closed
Bug 1698697
Opened 4 years ago
Closed 4 years ago
error: call to implicitly-deleted copy constructor of 'mozilla::BlockingResourceBase::AcquisitionState'
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
88 Branch
People
(Reporter: glandium, Assigned: glandium)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
When enabling callstack tracking in BlockingResourceBase.h, the build fails with:
In file included from /tmp/central/xpcom/threads/IdleTaskRunner.cpp:7:
In file included from /tmp/central/xpcom/threads/IdleTaskRunner.h:12:
In file included from /tmp/central/xpcom/threads/nsThreadUtils.h:14:
In file included from /tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/EventQueue.h:10:
In file included from /tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Mutex.h:10:
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/BlockingResourceBase.h:201:51: error: call to implicitly-deleted copy constructor of 'mozilla::BlockingResourceBase::AcquisitionState' (aka 'Maybe<AutoTArray<void *, kAcquisitionStateStackSize>>')
AcquisitionState GetAcquisitionState() { return mAcquired; }
^~~~~~~~~
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:376:7: note: copy constructor of 'Maybe<AutoTArray<void *, 24>>' is implicitly deleted because base class 'detail::Maybe_CopyMove_Enabler<AutoTArray<void *, 24>>' has a deleted copy constructor
public detail::Maybe_CopyMove_Enabler<T> {
^
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:209:3: note: copy constructor is implicitly deleted because 'Maybe_CopyMove_Enabler<AutoTArray<void *, 24>, false, false, true>' has a user-declared move constructor
MOZ_MAYBE_MOVE_OPS()
^
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:131:13: note: expanded from macro 'MOZ_MAYBE_MOVE_OPS'
constexpr Maybe_CopyMove_Enabler(Maybe_CopyMove_Enabler&& aOther) { \
^
In file included from /tmp/central/xpcom/threads/IdleTaskRunner.cpp:7:
In file included from /tmp/central/xpcom/threads/IdleTaskRunner.h:12:
In file included from /tmp/central/xpcom/threads/nsThreadUtils.h:14:
In file included from /tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/EventQueue.h:10:
In file included from /tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Mutex.h:10:
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/BlockingResourceBase.h:210:15: error: object of type 'mozilla::BlockingResourceBase::AcquisitionState' (aka 'Maybe<AutoTArray<void *, kAcquisitionStateStackSize>>') cannot be assigned because its copy assignment operator is implicitly deleted
mAcquired = aAcquisitionState;
^
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:376:7: note: copy assignment operator of 'Maybe<AutoTArray<void *, 24>>' is implicitly deleted because base class 'detail::Maybe_CopyMove_Enabler<AutoTArray<void *, 24>>' has a deleted copy assignment operator
public detail::Maybe_CopyMove_Enabler<T> {
^
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:209:3: note: copy assignment operator is implicitly deleted because 'Maybe_CopyMove_Enabler<AutoTArray<void *, 24>, false, false, true>' has a user-declared move constructor
MOZ_MAYBE_MOVE_OPS()
^
/tmp/central/obj-x86_64-pc-linux-gnu/dist/include/mozilla/Maybe.h:131:13: note: expanded from macro 'MOZ_MAYBE_MOVE_OPS'
constexpr Maybe_CopyMove_Enabler(Maybe_CopyMove_Enabler&& aOther) { \
^
2 errors generated.
Assignee | ||
Comment 1•4 years ago
|
||
Since GetAcquisitionState is never used independently of
ClearAcquisitionState, we change it to TakeAcquisitionState, such that
we don't require an expensive array copy in this case.
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/78e705fb75a3
Fix BlockingResourceBase code with callstack tracking enabled. r=nika
Updated•4 years ago
|
Keywords: regression
Comment 3•4 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 4 years ago
status-firefox88:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 88 Branch
Updated•4 years ago
|
Updated•4 years ago
|
Has Regression Range: --- → yes
You need to log in
before you can comment on or make changes to this bug.
Description
•