public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely@redhat.com>
To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org
Subject: [committed 4/8] libstdc++: Rename __cpp_lib_constexpr_invoke macro
Date: Wed, 22 Apr 2020 22:58:54 +0100	[thread overview]
Message-ID: <eca477d16c3fd4ef1fbd559ccff11ec778d387bc.1587592482.git.jwakely@redhat.com> (raw)
In-Reply-To: <cover.1587592482.git.jwakely@redhat.com>

This macro was renamed after it was added to the working draft, but we
never renamed it  in libstdc++. We haven't made a release with the old
macro name, so I see no need to keep it around.

	* include/std/functional (__cpp_lib_constexpr_invoke): Rename to
	__cpp_lib_constexpr_functional.
	* include/std/version (__cpp_lib_constexpr_invoke): Likewise.
	* testsuite/20_util/function_objects/invoke/constexpr.cc: Adjust.
---
 libstdc++-v3/ChangeLog                                       | 5 +++++
 libstdc++-v3/include/std/functional                          | 2 +-
 libstdc++-v3/include/std/version                             | 2 +-
 .../testsuite/20_util/function_objects/invoke/constexpr.cc   | 4 ++--
 4 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 182f5dc4b7e..7053a63ee91 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,5 +1,10 @@
 2020-04-22  Jonathan Wakely  <jwakely@redhat.com>
 
+	* include/std/functional (__cpp_lib_constexpr_invoke): Rename to
+	__cpp_lib_constexpr_functional.
+	* include/std/version (__cpp_lib_constexpr_invoke): Likewise.
+	* testsuite/20_util/function_objects/invoke/constexpr.cc: Adjust.
+
 	* include/bits/ptr_traits.h (__cpp_lib_constexpr_memory): Define to
 	indicate P1006R1 support.
 	(__cpp_lib_to_address): Define to indicate P0653R2 support.
diff --git a/libstdc++-v3/include/std/functional b/libstdc++-v3/include/std/functional
index faa7e85c114..2a9b2a003db 100644
--- a/libstdc++-v3/include/std/functional
+++ b/libstdc++-v3/include/std/functional
@@ -76,7 +76,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 #if __cplusplus >= 201703L
 # define __cpp_lib_invoke 201411L
 # if __cplusplus > 201703L
-#  define __cpp_lib_constexpr_invoke 201907L
+#  define __cpp_lib_constexpr_functional 201907L
 # endif
 
   /// Invoke a callable object.
diff --git a/libstdc++-v3/include/std/version b/libstdc++-v3/include/std/version
index 3b1fd700069..77255915c4d 100644
--- a/libstdc++-v3/include/std/version
+++ b/libstdc++-v3/include/std/version
@@ -190,7 +190,7 @@
 #define __cpp_lib_constexpr_algorithms 201806L
 #define __cpp_lib_constexpr_complex 201711L
 #define __cpp_lib_constexpr_dynamic_alloc 201907L
-#define __cpp_lib_constexpr_invoke 201907L
+#define __cpp_lib_constexpr_functional 201907L
 #define __cpp_lib_constexpr_memory 201811L
 #define __cpp_lib_constexpr_numeric 201911L
 #define __cpp_lib_erase_if 202002L
diff --git a/libstdc++-v3/testsuite/20_util/function_objects/invoke/constexpr.cc b/libstdc++-v3/testsuite/20_util/function_objects/invoke/constexpr.cc
index 89cb9ca0fcc..3df48d44f49 100644
--- a/libstdc++-v3/testsuite/20_util/function_objects/invoke/constexpr.cc
+++ b/libstdc++-v3/testsuite/20_util/function_objects/invoke/constexpr.cc
@@ -20,9 +20,9 @@
 
 #include <functional>
 
-#ifndef __cpp_lib_constexpr_invoke
+#ifndef __cpp_lib_constexpr_functional
 # error "Feature test macro for constexpr invoke is missing"
-#elif __cpp_lib_constexpr_invoke < 201907L
+#elif __cpp_lib_constexpr_functional < 201907L
 # error "Feature test macro for constexpr invoke has wrong value"
 #endif
 
-- 
2.25.3


  parent reply	other threads:[~2020-04-22 21:58 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-22 21:57 [committed 0/8] libstdc++: Add/update/fix feature test macros Jonathan Wakely
2020-04-22 21:58 ` [committed 1/8] libstdc++: Update value of __cpp_lib_jthread macro Jonathan Wakely
2020-04-22 21:58 ` [committed 2/8] libstdc++: Remove non-standard feature test macros Jonathan Wakely
2020-04-22 21:58 ` [committed 3/8] libstdc++: Add missing " Jonathan Wakely
2020-04-22 21:58 ` Jonathan Wakely [this message]
2020-04-22 21:59 ` [committed 5/8] libstdc++: Update __cpp_lib_concepts value Jonathan Wakely
2020-04-22 21:59 ` [committed 6/8] libstdc++: Do not define __cpp_lib_constexpr_algorithms in <utility> Jonathan Wakely
2020-04-22 21:59 ` [committed 7/8] libstdc++: Update (and revert) value of __cpp_lib_array_constexpr Jonathan Wakely
2020-04-23 20:44   ` Jonathan Wakely
2020-04-22 21:59 ` [committed 8/8] libstdc++: Define __cpp_lib_execution feature test macro Jonathan Wakely
2020-04-23 20:41 ` [committed 9/8] libstdc++: Define __cpp_lib_three_way_comparison for freestanding Jonathan Wakely
2020-04-23 20:46 ` [committed 0/8] libstdc++: Add/update/fix feature test macros Jonathan Wakely
2020-04-28 22:52 ` [committed 10/8] libstdc++: Fixes for feature test macros (PR 91480) Jonathan Wakely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=eca477d16c3fd4ef1fbd559ccff11ec778d387bc.1587592482.git.jwakely@redhat.com \
    --to=jwakely@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=libstdc++@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).