Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Simon Marchi <simark@simark.ca>
To: Tom Tromey <tromey@adacore.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] Remove #ifdef from cooked-index-entry.c
Date: Wed, 28 Oct 2026 13:33:31 -0400	[thread overview]
Message-ID: <f900b513-33e6-480b-bb0a-adbaa02090ba@simark.ca> (raw)
In-Reply-To: <20261028172301.1376846-1-tromey@adacore.com>

On 10/28/26 1:23 PM, Tom Tromey wrote:
> 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.

Nit: it's an #if, not an #ifdef.

For my curiosity, can you explain why constexpr was needed (or useful) in the first place?

The commit that added it is:

https://gitlab.com/gnutools/binutils-gdb/-/commit/2e724489260d02a528591eaea4710ce5aeeee0e8

but it doesn't talk about that.

Approved-By: Simon Marchi <simon.marchi@efficios.com>

Thanks,

Simon

  reply	other threads:[~2026-10-28 17:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-28 17:23 Tom Tromey
2026-10-28 17:33 ` Simon Marchi [this message]
2026-10-28 21:23   ` Tom Tromey

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=f900b513-33e6-480b-bb0a-adbaa02090ba@simark.ca \
    --to=simark@simark.ca \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@adacore.com \
    /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