[libcxx-commits] [libcxx] 5841140 - [libc++][modules] Fixes C++20 build errors.
Mark de Wever via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Dec 23 02:45:45 PST 2023
Author: Mark de Wever
Date: 2023-12-23T11:43:17+01:00
New Revision: 5841140e38c94f3d2b29354f67e70803d88ce174
URL: https://github.com/llvm/llvm-project/commit/5841140e38c94f3d2b29354f67e70803d88ce174
DIFF: https://github.com/llvm/llvm-project/commit/5841140e38c94f3d2b29354f67e70803d88ce174.diff
LOG: [libc++][modules] Fixes C++20 build errors.
Recent CI changes have disabled testing modules in different
configurations. This broke building the std and std.compat module in
C++20. This was found by the CI in #76246.
Added:
Modified:
libcxx/modules/std/algorithm.inc
Removed:
################################################################################
diff --git a/libcxx/modules/std/algorithm.inc b/libcxx/modules/std/algorithm.inc
index f6b35efa144f81..75e8a3af78dea2 100644
--- a/libcxx/modules/std/algorithm.inc
+++ b/libcxx/modules/std/algorithm.inc
@@ -16,7 +16,9 @@ export namespace std {
using std::ranges::in_in_result;
using std::ranges::in_out_out_result;
using std::ranges::in_out_result;
+#if _LIBCPP_STD_VER >= 23
using std::ranges::in_value_result;
+#endif
using std::ranges::min_max_result;
// using std::ranges::out_value_result;
} // namespace ranges
@@ -40,6 +42,7 @@ export namespace std {
using std::ranges::none_of;
}
+#if _LIBCPP_STD_VER >= 23
// [alg.contains], contains
namespace ranges {
using std::ranges::contains;
@@ -47,6 +50,7 @@ export namespace std {
using std::ranges::contains_subrange;
#endif
} // namespace ranges
+#endif // _LIBCPP_STD_VER >= 23
// [alg.foreach], for each
using std::for_each;
More information about the libcxx-commits
mailing list