[libcxx-commits] [PATCH] D152643: [libc++][spaceship] P1614R2: Removed ops from `unordered_multiset`, `unordered_set`
Hristo Hristov via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sun Jun 11 09:40:42 PDT 2023
H-G-Hristov created this revision.
Herald added a subscriber: yaxunl.
Herald added a project: All.
H-G-Hristov updated this revision to Diff 530275.
H-G-Hristov added a comment.
H-G-Hristov updated this revision to Diff 530287.
H-G-Hristov published this revision for review.
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++.
Updated table
H-G-Hristov added a comment.
Rebased
Implements parts of P1614R2:
- Removed ops from `unordered_multiset`,
- Removed ops from `unordered_set`
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D152643
Files:
libcxx/docs/Status/SpaceshipProjects.csv
libcxx/include/unordered_set
Index: libcxx/include/unordered_set
===================================================================
--- libcxx/include/unordered_set
+++ libcxx/include/unordered_set
@@ -232,7 +232,7 @@
template <class Value, class Hash, class Pred, class Alloc>
bool
operator!=(const unordered_set<Value, Hash, Pred, Alloc>& x,
- const unordered_set<Value, Hash, Pred, Alloc>& y);
+ const unordered_set<Value, Hash, Pred, Alloc>& y); // removed in C++20
template <class Value, class Hash = hash<Value>, class Pred = equal_to<Value>,
class Alloc = allocator<Value>>
@@ -454,7 +454,7 @@
template <class Value, class Hash, class Pred, class Alloc>
bool
operator!=(const unordered_multiset<Value, Hash, Pred, Alloc>& x,
- const unordered_multiset<Value, Hash, Pred, Alloc>& y);
+ const unordered_multiset<Value, Hash, Pred, Alloc>& y); // removed in C++20
} // std
*/
@@ -1150,6 +1150,8 @@
return true;
}
+#if _LIBCPP_STD_VER <= 17
+
template <class _Value, class _Hash, class _Pred, class _Alloc>
inline _LIBCPP_INLINE_VISIBILITY
bool
@@ -1159,6 +1161,8 @@
return !(__x == __y);
}
+#endif
+
template <class _Value, class _Hash = hash<_Value>, class _Pred = equal_to<_Value>,
class _Alloc = allocator<_Value> >
class _LIBCPP_TEMPLATE_VIS unordered_multiset
@@ -1792,6 +1796,8 @@
return true;
}
+#if _LIBCPP_STD_VER <= 17
+
template <class _Value, class _Hash, class _Pred, class _Alloc>
inline _LIBCPP_INLINE_VISIBILITY
bool
@@ -1801,6 +1807,8 @@
return !(__x == __y);
}
+#endif
+
_LIBCPP_END_NAMESPACE_STD
#if _LIBCPP_STD_VER >= 17
Index: libcxx/docs/Status/SpaceshipProjects.csv
===================================================================
--- libcxx/docs/Status/SpaceshipProjects.csv
+++ libcxx/docs/Status/SpaceshipProjects.csv
@@ -97,8 +97,8 @@
| `set <https://reviews.llvm.org/D148416>`_",[expos.only.func],Hristo Hristov,|Complete|
| `[unord.map.syn] <https://wg21.link/unord.map.syn>`_,"| remove ops `unordered_map`
| remove ops `unordered_multimap`",None,Unassigned,|Not Started|
-| `[unordered.set.syn] <https://wg21.link/unordered.set.syn>`_,"| remove ops `unordered_set`
-| remove ops `unordered_multiset`",None,Unassigned,|Not Started|
+| `[unordered.set.syn] <https://wg21.link/unordered.set.syn>`_,"| remove ops `unordered_set <https://reviews.llvm.org/D152643>`_
+| remove ops `unordered_multiset <https://reviews.llvm.org/D152643>`_",None,Hristo Hristov,|Complete|
| `[queue.syn] <https://wg21.link/queue.syn>`_,| `queue <https://reviews.llvm.org/D146066>`_,None,Hristo Hristov,|Complete|
| `[stack.syn] <https://wg21.link/stack.syn>`_,| `stack <https://reviews.llvm.org/D146094>`_,None,Hristo Hristov,|Complete|
| `[queue.ops] <https://wg21.link/queue.ops>`_,| `queue <https://reviews.llvm.org/D146066>`_,None,Hristo Hristov,|Complete|
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D152643.530287.patch
Type: text/x-patch
Size: 2903 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20230611/87284845/attachment.bin>
More information about the libcxx-commits
mailing list