public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Keith Seitz <keiths@redhat.com>
Cc: Tom Tromey <tom@tromey.com>,
	 Keith Seitz via Gdb-patches <gdb-patches@sourceware.org>
Subject: Re: [PATCH] Allow strings with printf/eval
Date: Tue, 25 Apr 2023 14:21:59 -0600	[thread overview]
Message-ID: <871qk7pva0.fsf@tromey.com> (raw)
In-Reply-To: <514297cf-4c9e-f6bb-95f3-3ebdec9bb13e@redhat.com> (Keith Seitz's message of "Tue, 25 Apr 2023 08:50:54 -0700")

>>>>> "Keith" == Keith Seitz <keiths@redhat.com> writes:

Keith> On 4/24/23 10:12, Tom Tromey wrote:
>>>>>>> "Keith" == Keith Seitz via Gdb-patches <gdb-patches@sourceware.org> writes:
Keith> (gdb) printf "%s\n", "hello"
Keith> evaluation of this expression requires the target program to be active
>> This is https://sourceware.org/bugzilla/show_bug.cgi?id=13098

Keith> Thank you for that bz; I will add a reference in the commit log.

Keith> -  if (value->type ()->code () != TYPE_CODE_PTR
Keith> -      && value->lval () == lval_internalvar
Keith> +  if (((value->type ()->code () != TYPE_CODE_PTR && value->lval () == lval_internalvar)
Keith> +       || (value->type ()->code () == TYPE_CODE_ARRAY && value->lval () == not_lval))
>> I wonder if lval check is necessary here.

Keith> It does not appear to be, but I erred on the overly conservative side when
Keith> implementing the change. Regression testing shows no differences when
Keith> removing that lval check.

Keith> I've removed it locally.

I think with those 2 small changes, the patch is ok.  Thank you.

Tom

  reply	other threads:[~2023-04-25 20:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-23 17:21 Keith Seitz
2023-04-24 17:12 ` Tom Tromey
2023-04-25 15:50   ` Keith Seitz
2023-04-25 20:21     ` Tom Tromey [this message]
2023-04-28 17:45       ` Keith Seitz

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=871qk7pva0.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    --cc=keiths@redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).