aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/std/latch
diff options
context:
space:
mode:
Diffstat (limited to 'libstdc++-v3/include/std/latch')
-rw-r--r--libstdc++-v3/include/std/latch10
1 files changed, 4 insertions, 6 deletions
diff --git a/libstdc++-v3/include/std/latch b/libstdc++-v3/include/std/latch
index a5a92fa..27cd80d 100644
--- a/libstdc++-v3/include/std/latch
+++ b/libstdc++-v3/include/std/latch
@@ -33,18 +33,17 @@
#include <bits/requires_hosted.h> // concurrency
-#if __cplusplus > 201703L
+#define __glibcxx_want_latch
+#include <bits/version.h>
+#ifdef __cpp_lib_latch // C++ >= 20 && atomic_wait
#include <bits/atomic_base.h>
#include <ext/numeric_traits.h>
-#if __cpp_lib_atomic_wait
namespace std _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
-#define __cpp_lib_latch 201907L
-
class latch
{
public:
@@ -91,6 +90,5 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
};
_GLIBCXX_END_NAMESPACE_VERSION
} // namespace
-#endif // __cpp_lib_atomic_wait
-#endif // __cplusplus > 201703L
+#endif // __cpp_lib_latch
#endif // _GLIBCXX_LATCH