Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "Ijaz, Abdul B" <abdul.b.ijaz@intel.com>
Cc: gdb-patches@sourceware.org, pedro@palves.net,
	philippe.waroquiers@skynet.be, aburgess@redhat.com,
	tankut.baris.aktemur@intel.com, christina.schimpe@intel.com,
	lsix@lancelotsix.com, tom@tromey.com
Subject: Re: [PATCH v11 1/2] gdb: add annotation in 'info locals' command for variables shadowing case
Date: Fri, 28 Nov 2025 17:23:39 +0200	[thread overview]
Message-ID: <86qzti89l0.fsf@gnu.org> (raw)
In-Reply-To: <SA1PR11MB6846BDC9397F07984BF04364CBDCA@SA1PR11MB6846.namprd11.prod.outlook.com> (abdul.b.ijaz@intel.com)

> From: "Ijaz, Abdul B" <abdul.b.ijaz@intel.com>
> CC: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>,
> 	"pedro@palves.net" <pedro@palves.net>, "philippe.waroquiers@skynet.be"
> 	<philippe.waroquiers@skynet.be>, "aburgess@redhat.com" <aburgess@redhat.com>,
> 	"Aktemur, Tankut Baris" <tankut.baris.aktemur@intel.com>, "Schimpe,
>  Christina" <christina.schimpe@intel.com>, "lsix@lancelotsix.com"
> 	<lsix@lancelotsix.com>, "tom@tromey.com" <tom@tromey.com>
> Date: Fri, 28 Nov 2025 14:37:34 +0000
> 
> Hi Eli,
> 
> Thanks a lot for the feedback. Please review my feedback below.
> 
> >> +  the output of this command for variables shadowing case.
> 
> Eli>This sounds like the annotations are only shown when variables' values are shadowed.  Is that really the case?  If so, why not show also annotations for the non-shadowed variables?
> 
> Abdul>Yes it the case. As otherwise this information is not useful. For example if variable is shown for "info locals" 5 times then 4 instances will have shadowed annotation with location info while the one instance will be without it. So it will be easier for user to identify the variable in current scope from the rest but any variable is only shown once then the information is not that useful.

I think it will be better if we would show the last line before the
location of PC where each local got its value.

I will not argue about this anymore, but I'd like to hear what others
think about that.

  reply	other threads:[~2025-11-28 15:25 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-28 12:03 [PATCH v11 0/2] " Abdul Basit Ijaz
2025-11-28 12:03 ` [PATCH v11 1/2] gdb: " Abdul Basit Ijaz
2025-11-28 14:15   ` Eli Zaretskii
2025-11-28 14:37     ` Ijaz, Abdul B
2025-11-28 15:23       ` Eli Zaretskii [this message]
2025-11-28 12:03 ` [PATCH v11 2/2] gdb: add shadowed field in '-stack-list-locals/variables' mi commands Abdul Basit Ijaz
2025-11-28 14:21   ` Eli Zaretskii
2025-11-28 15:09     ` Ijaz, Abdul B

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=86qzti89l0.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=abdul.b.ijaz@intel.com \
    --cc=aburgess@redhat.com \
    --cc=christina.schimpe@intel.com \
    --cc=gdb-patches@sourceware.org \
    --cc=lsix@lancelotsix.com \
    --cc=pedro@palves.net \
    --cc=philippe.waroquiers@skynet.be \
    --cc=tankut.baris.aktemur@intel.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