mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
src: remove OnScopeLeaveImpl's move assignment overload
... as it's not valid implementation and also has not been used PR-URL: https://github.com/nodejs/node/pull/48732 Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
@@ -577,12 +577,6 @@ struct OnScopeLeaveImpl {
|
||||
: fn_(std::move(other.fn_)), active_(other.active_) {
|
||||
other.active_ = false;
|
||||
}
|
||||
OnScopeLeaveImpl& operator=(OnScopeLeaveImpl&& other) {
|
||||
if (this == &other) return *this;
|
||||
this->~OnScopeLeave();
|
||||
new (this)OnScopeLeaveImpl(std::move(other));
|
||||
return *this;
|
||||
}
|
||||
};
|
||||
|
||||
// Run a function when exiting the current scope. Used like this:
|
||||
|
||||
Reference in New Issue
Block a user