summaryrefslogtreecommitdiff
path: root/sys-devel/gdb/files/gdb-8.3.50.20190312-c++17.patch
blob: c134cbcae8df8210737627545d9b8948090cd8a9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
https://bugs.gentoo.org/680232

--- a/gdb/unittests/string_view-selftests.c
+++ b/gdb/unittests/string_view-selftests.c
@@ -170,10 +170,12 @@ run_tests ()
 } /* namespace string_view */
 } /* namespace selftests */
 
+#endif /* __cplusplus < 201703L */
+
 void
 _initialize_string_view_selftests ()
 {
+#if defined(GDB_STRING_VIEW)
   selftests::register_test ("string_view", selftests::string_view::run_tests);
+#endif
 }
-
-#endif /* __cplusplus < 201703L */