Skip to content

Commit 45d9c2d

Browse files
burblebeetkoeppe
authored andcommitted
LWG4557 Remove constexpr from owner_less and owner_before
Fixes NB US 75-138 (C++26 CD).
1 parent 87ab4fd commit 45d9c2d

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

source/memory.tex

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3468,9 +3468,9 @@
34683468
constexpr long use_count() const noexcept;
34693469
constexpr explicit operator bool() const noexcept;
34703470
template<class U>
3471-
constexpr bool owner_before(const shared_ptr<U>& b) const noexcept;
3471+
bool owner_before(const shared_ptr<U>& b) const noexcept;
34723472
template<class U>
3473-
constexpr bool owner_before(const weak_ptr<U>& b) const noexcept;
3473+
bool owner_before(const weak_ptr<U>& b) const noexcept;
34743474
size_t owner_hash() const noexcept;
34753475
template<class U>
34763476
constexpr bool owner_equal(const shared_ptr<U>& b) const noexcept;
@@ -4076,8 +4076,8 @@
40764076

40774077
\indexlibrarymember{owner_before}{shared_ptr}%
40784078
\begin{itemdecl}
4079-
template<class U> constexpr bool owner_before(const shared_ptr<U>& b) const noexcept;
4080-
template<class U> constexpr bool owner_before(const weak_ptr<U>& b) const noexcept;
4079+
template<class U> bool owner_before(const shared_ptr<U>& b) const noexcept;
4080+
template<class U> bool owner_before(const weak_ptr<U>& b) const noexcept;
40814081
\end{itemdecl}
40824082

40834083
\begin{itemdescr}
@@ -4793,9 +4793,9 @@
47934793
constexpr bool expired() const noexcept;
47944794
constexpr shared_ptr<T> lock() const noexcept;
47954795
template<class U>
4796-
constexpr bool owner_before(const shared_ptr<U>& b) const noexcept;
4796+
bool owner_before(const shared_ptr<U>& b) const noexcept;
47974797
template<class U>
4798-
constexpr bool owner_before(const weak_ptr<U>& b) const noexcept;
4798+
bool owner_before(const weak_ptr<U>& b) const noexcept;
47994799
size_t owner_hash() const noexcept;
48004800
template<class U>
48014801
constexpr bool owner_equal(const shared_ptr<U>& b) const noexcept;
@@ -4992,8 +4992,8 @@
49924992

49934993
\indexlibrarymember{owner_before}{weak_ptr}%
49944994
\begin{itemdecl}
4995-
template<class U> constexpr bool owner_before(const shared_ptr<U>& b) const noexcept;
4996-
template<class U> constexpr bool owner_before(const weak_ptr<U>& b) const noexcept;
4995+
template<class U> bool owner_before(const shared_ptr<U>& b) const noexcept;
4996+
template<class U> bool owner_before(const weak_ptr<U>& b) const noexcept;
49974997
\end{itemdecl}
49984998

49994999
\begin{itemdescr}
@@ -5067,26 +5067,26 @@
50675067
template<class T = void> struct owner_less;
50685068

50695069
template<class T> struct owner_less<shared_ptr<T>> {
5070-
constexpr bool operator()(const shared_ptr<T>&, const shared_ptr<T>&) const noexcept;
5071-
constexpr bool operator()(const shared_ptr<T>&, const weak_ptr<T>&) const noexcept;
5072-
constexpr bool operator()(const weak_ptr<T>&, const shared_ptr<T>&) const noexcept;
5070+
bool operator()(const shared_ptr<T>&, const shared_ptr<T>&) const noexcept;
5071+
bool operator()(const shared_ptr<T>&, const weak_ptr<T>&) const noexcept;
5072+
bool operator()(const weak_ptr<T>&, const shared_ptr<T>&) const noexcept;
50735073
};
50745074

50755075
template<class T> struct owner_less<weak_ptr<T>> {
5076-
constexpr bool operator()(const weak_ptr<T>&, const weak_ptr<T>&) const noexcept;
5077-
constexpr bool operator()(const shared_ptr<T>&, const weak_ptr<T>&) const noexcept;
5078-
constexpr bool operator()(const weak_ptr<T>&, const shared_ptr<T>&) const noexcept;
5076+
bool operator()(const weak_ptr<T>&, const weak_ptr<T>&) const noexcept;
5077+
bool operator()(const shared_ptr<T>&, const weak_ptr<T>&) const noexcept;
5078+
bool operator()(const weak_ptr<T>&, const shared_ptr<T>&) const noexcept;
50795079
};
50805080

50815081
template<> struct owner_less<void> {
50825082
template<class T, class U>
5083-
constexpr bool operator()(const shared_ptr<T>&, const shared_ptr<U>&) const noexcept;
5083+
bool operator()(const shared_ptr<T>&, const shared_ptr<U>&) const noexcept;
50845084
template<class T, class U>
5085-
constexpr bool operator()(const shared_ptr<T>&, const weak_ptr<U>&) const noexcept;
5085+
bool operator()(const shared_ptr<T>&, const weak_ptr<U>&) const noexcept;
50865086
template<class T, class U>
5087-
constexpr bool operator()(const weak_ptr<T>&, const shared_ptr<U>&) const noexcept;
5087+
bool operator()(const weak_ptr<T>&, const shared_ptr<U>&) const noexcept;
50885088
template<class T, class U>
5089-
constexpr bool operator()(const weak_ptr<T>&, const weak_ptr<U>&) const noexcept;
5089+
bool operator()(const weak_ptr<T>&, const weak_ptr<U>&) const noexcept;
50905090

50915091
using is_transparent = @\unspec@;
50925092
};

0 commit comments

Comments
 (0)