Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Tom Tromey <tom@tromey.com>
Cc: gdb-patches@sourceware.org, Simon Marchi <simon.marchi@efficios.com>
Subject: Re: [PATCH] gdb/dwarf: rename dwarf2_per_cu_data -> dwarf2_per_cu
Date: Mon, 3 Mar 2025 15:55:21 -0500	[thread overview]
Message-ID: <9003f9b2-dc1d-421d-bb85-1a62daf1b7e4@polymtl.ca> (raw)
In-Reply-To: <87mse13lf1.fsf@tromey.com>

On 3/3/25 3:32 PM, Tom Tromey wrote:
>>>>>> "simon" == simon marchi <simon.marchi@polymtl.ca> writes:
> 
> Simon> This scratches an itch I had for a while.  I don't know why this struct
> Simon> type has "data" in its name.  Others like "dwarf2_per_objfile" and
> Simon> "dwarf2_per_bfd" don't.  The primary job of a structure is to hold data,
> Simon> there's no need to specify it.  It also makes the name a bit shorter,
> Simon> which is always nice.
> 
> It's fine by me but I wonder if this is really the best final naming, as
> now we have dwarf2_cu and dwarf2_per_cu.

At least, dwarf2_per_cu is consistent with dwarf2_per_objfile and
dwarf2_per_bfd, and first nicely in the "dwarf2_per_objfile ->
dwarf2_per_bfd -> dwarf2_per_cu" hierarchy.

If I had to rename one, I would probably rename "dwarf2_cu", but I don't
know to what, because I have a hard time expressing what it is exactly.
Anyway, even if dwarf2_per_cu changes again in the future, I don't think
it's the end of the world to have this intermediary step.

> Approved-By: Tom Tromey <tom@tromey.com>

Thanks, will push.

Simon

      reply	other threads:[~2025-03-03 20:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-26  4:20 simon.marchi
2025-02-26 14:50 ` Guinevere Larsen
2025-02-26 17:02   ` Simon Marchi
2025-03-03 20:32 ` Tom Tromey
2025-03-03 20:55   ` Simon Marchi [this message]

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=9003f9b2-dc1d-421d-bb85-1a62daf1b7e4@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@efficios.com \
    --cc=tom@tromey.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