Skip to content

Commit 02bb202

Browse files
committed
[libc++] Fix -Wdeprecated-copy warnings in __bit_reference
Add a couple of default copy constructors to fix the warning. Reviewed By: dblaikie Differential Revision: https://reviews.llvm.org/D71395
1 parent e0b9666 commit 02bb202

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

libcxx/include/__bit_reference

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ public:
6262
return *this;
6363
}
6464

65+
__bit_reference(const __bit_reference&) = default;
66+
6567
_LIBCPP_INLINE_VISIBILITY
6668
__bit_reference& operator=(const __bit_reference& __x) _NOEXCEPT
6769
{return operator=(static_cast<bool>(__x));}
@@ -148,6 +150,7 @@ private:
148150
: __seg_(__s), __mask_(__m) {}
149151

150152
__bit_const_reference& operator=(const __bit_const_reference& __x);
153+
__bit_const_reference(const __bit_const_reference&) = default;
151154
};
152155

153156
// find

0 commit comments

Comments
 (0)