[committed] libstdc++: Disable deprecated warnings for std::rel_ops in std.cc

Message ID 20241202161916.54401-1-jwakely@redhat.com
State Committed
Commit 27e5d860879c8f6075231e2a547fe8ead5f382e4
Headers
Series [committed] libstdc++: Disable deprecated warnings for std::rel_ops in std.cc |

Checks

Context Check Description
linaro-tcwg-bot/tcwg_gcc_build--master-aarch64 success Build passed
linaro-tcwg-bot/tcwg_gcc_check--master-aarch64 fail Patch failed to apply
linaro-tcwg-bot/tcwg_gcc_build--master-arm fail Patch failed to apply

Commit Message

Jonathan Wakely Dec. 2, 2024, 4:19 p.m. UTC
  This avoids some warnings when building the std module.

libstdc++-v3/ChangeLog:

	* src/c++23/std.cc.in: Disable deprecated warnings when
	exporting std::rel_ops members.
---

Pushed to trunk.

 libstdc++-v3/src/c++23/std.cc.in | 3 +++
 1 file changed, 3 insertions(+)
  

Patch

diff --git a/libstdc++-v3/src/c++23/std.cc.in b/libstdc++-v3/src/c++23/std.cc.in
index 16e66c3d921..7a0ff8edad6 100644
--- a/libstdc++-v3/src/c++23/std.cc.in
+++ b/libstdc++-v3/src/c++23/std.cc.in
@@ -3151,6 +3151,8 @@  export namespace std
   using std::piecewise_construct_t;
   using std::tuple_element;
   using std::tuple_size;
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
   namespace rel_ops
   {
     using std::rel_ops::operator!=;
@@ -3158,6 +3160,7 @@  export namespace std
     using std::rel_ops::operator<=;
     using std::rel_ops::operator>=;
   }
+#pragma GCC diagnostic pop
 #if __cpp_lib_unreachable
   using std::unreachable;
 #endif