aboutsummaryrefslogtreecommitdiff
path: root/libcxx/include
diff options
context:
space:
mode:
authorLouis Dionne <ldionne.2@gmail.com>2022-05-10 15:27:52 -0400
committerLouis Dionne <ldionne.2@gmail.com>2022-05-25 03:44:48 -0400
commit643df8fa8ef58d883cbb554c7e71910dc8a8673c (patch)
treef169cbae9b61066ce029b284e2ab2d5d43cded0c /libcxx/include
parent9698a445c664e6f0da5727364338ee99de537d6a (diff)
downloadllvm-643df8fa8ef58d883cbb554c7e71910dc8a8673c.zip
llvm-643df8fa8ef58d883cbb554c7e71910dc8a8673c.tar.gz
llvm-643df8fa8ef58d883cbb554c7e71910dc8a8673c.tar.bz2
[libc++] Make sure that all headers can be included with modules enabled
This commit ensures that we can include all libc++ headers with modules enabled. It adds a test to ensure that this doesn't regress, which is necessary because our modules CI job does not build in all Standard modes. Differential Revision: https://reviews.llvm.org/D125331
Diffstat (limited to 'libcxx/include')
-rw-r--r--libcxx/include/__filesystem/u8path.h8
-rw-r--r--libcxx/include/barrier1
-rw-r--r--libcxx/include/latch1
-rw-r--r--libcxx/include/module.modulemap4
-rw-r--r--libcxx/include/semaphore1
-rw-r--r--libcxx/include/span1
6 files changed, 12 insertions, 4 deletions
diff --git a/libcxx/include/__filesystem/u8path.h b/libcxx/include/__filesystem/u8path.h
index ee25521..d35faa1 100644
--- a/libcxx/include/__filesystem/u8path.h
+++ b/libcxx/include/__filesystem/u8path.h
@@ -10,11 +10,19 @@
#ifndef _LIBCPP___FILESYSTEM_U8PATH_H
#define _LIBCPP___FILESYSTEM_U8PATH_H
+#include <__algorithm/unwrap_iter.h>
#include <__availability>
#include <__config>
#include <__filesystem/path.h>
+#include <string>
#include <type_traits>
+// Only required on Windows for __widen_from_utf8, and included conservatively
+// because it requires support for localization.
+#if defined(_LIBCPP_WIN32API)
+# include <locale>
+#endif
+
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
# pragma GCC system_header
#endif
diff --git a/libcxx/include/barrier b/libcxx/include/barrier
index 36ea6f58..f03c089 100644
--- a/libcxx/include/barrier
+++ b/libcxx/include/barrier
@@ -50,6 +50,7 @@ namespace std
#include <__config>
#include <__thread/timed_backoff_policy.h>
#include <atomic>
+#include <limits>
#ifndef _LIBCPP_HAS_NO_TREE_BARRIER
# include <memory>
#endif
diff --git a/libcxx/include/latch b/libcxx/include/latch
index 21abbad..8593675 100644
--- a/libcxx/include/latch
+++ b/libcxx/include/latch
@@ -44,6 +44,7 @@ namespace std
#include <__availability>
#include <__config>
#include <atomic>
+#include <limits>
#include <version>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
diff --git a/libcxx/include/module.modulemap b/libcxx/include/module.modulemap
index 132793f..6a771ea 100644
--- a/libcxx/include/module.modulemap
+++ b/libcxx/include/module.modulemap
@@ -3,7 +3,6 @@
// include cycle.
module std_config [system] [extern_c] {
header "__config"
- header "__config_site"
export *
}
@@ -370,7 +369,6 @@ module std [system] {
export *
}
module barrier {
- requires cplusplus14
header "barrier"
export *
}
@@ -698,7 +696,6 @@ module std [system] {
}
}
module latch {
- requires cplusplus14
header "latch"
export *
}
@@ -906,7 +903,6 @@ module std [system] {
export *
}
module semaphore {
- requires cplusplus14
header "semaphore"
export *
}
diff --git a/libcxx/include/semaphore b/libcxx/include/semaphore
index ce1fa69..228cf77 100644
--- a/libcxx/include/semaphore
+++ b/libcxx/include/semaphore
@@ -52,6 +52,7 @@ using binary_semaphore = counting_semaphore<1>;
#include <__thread/timed_backoff_policy.h>
#include <__threading_support>
#include <atomic>
+#include <limits>
#include <version>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
diff --git a/libcxx/include/span b/libcxx/include/span
index 98ecfd4..15564d8 100644
--- a/libcxx/include/span
+++ b/libcxx/include/span
@@ -138,6 +138,7 @@ template<class R>
#include <__ranges/enable_borrowed_range.h>
#include <__ranges/enable_view.h>
#include <__ranges/size.h>
+#include <__utility/forward.h>
#include <array> // for array
#include <cstddef> // for byte
#include <iterator> // for iterators