summaryrefslogtreecommitdiff
path: root/libstdc++-v3
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2020-04-22 22:54:34 +0100
committerJonathan Wakely <jwakely@redhat.com>2020-04-22 22:54:34 +0100
commitaa12ab2e93b6fd7c0c5292504b0bbe2dd304e5ed (patch)
treea084f64664f0d9aac7d2929363322eaec52568b8 /libstdc++-v3
parent72d0ef73d2cd46bda2f28e1866d637cfe8edb208 (diff)
libstdc++: Update value of __cpp_lib_jthread macro
* include/std/condition_variable (__cpp_lib_jthread): Remove redundant definition. * include/std/stop_token (__cpp_lib_jthread): Update macro value to indicate P1869R1 support. * include/std/version (__cpp_lib_jthread): Update value. * testsuite/30_threads/condition_variable_any/stop_token/1.cc: Check for updated macro value. * testsuite/30_threads/condition_variable_any/stop_token/2.cc: Likewise. * testsuite/30_threads/jthread/1.cc: Likewise. * testsuite/30_threads/jthread/2.cc: Likewise. * testsuite/30_threads/stop_token/1.cc: Likewise. * testsuite/30_threads/stop_token/2.cc: Likewise.
Diffstat (limited to 'libstdc++-v3')
-rw-r--r--libstdc++-v3/ChangeLog14
-rw-r--r--libstdc++-v3/include/std/condition_variable3
-rw-r--r--libstdc++-v3/include/std/stop_token2
-rw-r--r--libstdc++-v3/include/std/version2
-rw-r--r--libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/1.cc2
-rw-r--r--libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/2.cc2
-rw-r--r--libstdc++-v3/testsuite/30_threads/jthread/1.cc2
-rw-r--r--libstdc++-v3/testsuite/30_threads/jthread/2.cc2
-rw-r--r--libstdc++-v3/testsuite/30_threads/stop_token/1.cc2
-rw-r--r--libstdc++-v3/testsuite/30_threads/stop_token/2.cc2
10 files changed, 23 insertions, 10 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 2e1484fefb5..dc0b1eecfb0 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,5 +1,19 @@
2020-04-22 Jonathan Wakely <jwakely@redhat.com>
+ * include/std/condition_variable (__cpp_lib_jthread): Remove
+ redundant definition.
+ * include/std/stop_token (__cpp_lib_jthread): Update macro value to
+ indicate P1869R1 support.
+ * include/std/version (__cpp_lib_jthread): Update value.
+ * testsuite/30_threads/condition_variable_any/stop_token/1.cc: Check
+ for updated macro value.
+ * testsuite/30_threads/condition_variable_any/stop_token/2.cc:
+ Likewise.
+ * testsuite/30_threads/jthread/1.cc: Likewise.
+ * testsuite/30_threads/jthread/2.cc: Likewise.
+ * testsuite/30_threads/stop_token/1.cc: Likewise.
+ * testsuite/30_threads/stop_token/2.cc: Likewise.
+
* testsuite/21_strings/basic_string/erasure.cc: Check for
__cpp_lib_erase_if macro.
* testsuite/23_containers/deque/erasure.cc: Add header name to #error
diff --git a/libstdc++-v3/include/std/condition_variable b/libstdc++-v3/include/std/condition_variable
index cc7f99f6921..2db9dff6c31 100644
--- a/libstdc++-v3/include/std/condition_variable
+++ b/libstdc++-v3/include/std/condition_variable
@@ -47,8 +47,7 @@
#include <bits/cxxabi_forced.h>
#if __cplusplus > 201703L
-#define __cpp_lib_jthread 201907L
-#include <stop_token>
+# include <stop_token>
#endif
#if defined(_GLIBCXX_HAS_GTHREADS)
diff --git a/libstdc++-v3/include/std/stop_token b/libstdc++-v3/include/std/stop_token
index 87beb08c71d..847d12f7454 100644
--- a/libstdc++-v3/include/std/stop_token
+++ b/libstdc++-v3/include/std/stop_token
@@ -34,7 +34,7 @@
#include <atomic>
#ifdef _GLIBCXX_HAS_GTHREADS
-# define __cpp_lib_jthread 201907L
+# define __cpp_lib_jthread 201911L
# include <bits/gthr.h>
# if __has_include(<semaphore>)
# include <semaphore>
diff --git a/libstdc++-v3/include/std/version b/libstdc++-v3/include/std/version
index 6d7dcc46023..dafb09f982a 100644
--- a/libstdc++-v3/include/std/version
+++ b/libstdc++-v3/include/std/version
@@ -191,7 +191,7 @@
#define __cpp_lib_erase_if 202002L
#define __cpp_lib_interpolate 201902L
#ifdef _GLIBCXX_HAS_GTHREADS
-# define __cpp_lib_jthread 201907L
+# define __cpp_lib_jthread 201911L
#endif
#define __cpp_lib_list_remove_return_type 201806L
#define __cpp_lib_math_constants 201907L
diff --git a/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/1.cc b/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/1.cc
index 59dafeb2d86..5b71cfb979f 100644
--- a/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/1.cc
+++ b/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/1.cc
@@ -22,6 +22,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <condition_variable>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <condition_variable>"
#endif
diff --git a/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/2.cc b/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/2.cc
index 7254024bbb3..0f017e43996 100644
--- a/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/2.cc
+++ b/libstdc++-v3/testsuite/30_threads/condition_variable_any/stop_token/2.cc
@@ -22,6 +22,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <version>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <version>"
#endif
diff --git a/libstdc++-v3/testsuite/30_threads/jthread/1.cc b/libstdc++-v3/testsuite/30_threads/jthread/1.cc
index dc47df9d205..d7c0a836b8b 100644
--- a/libstdc++-v3/testsuite/30_threads/jthread/1.cc
+++ b/libstdc++-v3/testsuite/30_threads/jthread/1.cc
@@ -23,6 +23,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <thread>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <thread>"
#endif
diff --git a/libstdc++-v3/testsuite/30_threads/jthread/2.cc b/libstdc++-v3/testsuite/30_threads/jthread/2.cc
index 9a0abbe8f70..4c196c3fe92 100644
--- a/libstdc++-v3/testsuite/30_threads/jthread/2.cc
+++ b/libstdc++-v3/testsuite/30_threads/jthread/2.cc
@@ -23,6 +23,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <version>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <version>"
#endif
diff --git a/libstdc++-v3/testsuite/30_threads/stop_token/1.cc b/libstdc++-v3/testsuite/30_threads/stop_token/1.cc
index 19294552fce..fffff3740c5 100644
--- a/libstdc++-v3/testsuite/30_threads/stop_token/1.cc
+++ b/libstdc++-v3/testsuite/30_threads/stop_token/1.cc
@@ -22,6 +22,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <stop_token>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <stop_token>"
#endif
diff --git a/libstdc++-v3/testsuite/30_threads/stop_token/2.cc b/libstdc++-v3/testsuite/30_threads/stop_token/2.cc
index 7254024bbb3..0f017e43996 100644
--- a/libstdc++-v3/testsuite/30_threads/stop_token/2.cc
+++ b/libstdc++-v3/testsuite/30_threads/stop_token/2.cc
@@ -22,6 +22,6 @@
#ifndef __cpp_lib_jthread
# error "Feature-test macro for jthread missing in <version>"
-#elif __cpp_lib_jthread != 201907L
+#elif __cpp_lib_jthread != 201911L
# error "Feature-test macro for jthread has wrong value in <version>"
#endif