Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH] Remove #ifdef from cooked-index-entry.c
@ 2026-10-28 17:23 Tom Tromey
  2026-10-28 17:33 ` Simon Marchi
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Tromey @ 2026-10-28 17:23 UTC (permalink / raw)
  To: gdb-patches; +Cc: Tom Tromey

cooked-index-entry.c has an #ifdef to work around a GCC 7.5.0 bug.
However, the workaround just removes a 'constexpr' which is not
needed.  The constexpr behavior was desirable in the past, but this
changed with commit 8cbf7d2a ("gdb/dwarf: remove unnecessary
comparison in cooked_index_entry::compare").

This removes the #ifdef and the constexpr.
---
 gdb/dwarf2/cooked-index-entry.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/gdb/dwarf2/cooked-index-entry.c b/gdb/dwarf2/cooked-index-entry.c
index 44b065157b8..c76c263117a 100644
--- a/gdb/dwarf2/cooked-index-entry.c
+++ b/gdb/dwarf2/cooked-index-entry.c
@@ -47,12 +47,7 @@ int
 cooked_index_entry::compare (const char *stra, const char *strb,
 			     comparison_mode mode)
 {
-#if defined (__GNUC__) && !defined (__clang__) && __GNUC__ <= 7
-  /* Work around error with gcc 7.5.0.  */
   auto munge = [] (char c) -> unsigned char
-#else
-  auto munge = [] (char c) constexpr -> unsigned char
-#endif
     {
       /* Treat '<' as if it ended the string.  This lets something
 	 like "func<t>" match "func<t<int>>".  See the "Breakpoints in

base-commit: aeed64b39aed57729f66ad51560d8964e8201e6e
-- 
2.56.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-10-28 21:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-28 17:23 [PATCH] Remove #ifdef from cooked-index-entry.c Tom Tromey
2026-10-28 17:33 ` Simon Marchi
2026-10-28 21:23   ` Tom Tromey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox