diff --git a/ctl/shared_ptr.h b/ctl/shared_ptr.h index 4c3b23ca7..5db5ec01c 100644 --- a/ctl/shared_ptr.h +++ b/ctl/shared_ptr.h @@ -444,6 +444,13 @@ class weak_ptr return *this; } + template + requires __::shared_ptr_compatible + weak_ptr& operator=(weak_ptr r) noexcept + { + weak_ptr(move(r)).swap(*this); + } + shared_ptr lock() const noexcept { if (expired())