Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Vladimir Prus <vladimir@codesourcery.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Fix breakpoint condition that use member variables.
Date: Sat, 22 Mar 2008 13:20:00 -0000	[thread overview]
Message-ID: <200803221620.10176.vladimir@codesourcery.com> (raw)
In-Reply-To: <u63vehq9d.fsf@gnu.org>

On Saturday 22 March 2008 15:55:42 Eli Zaretskii wrote:
> > From: Vladimir Prus <vladimir@codesourcery.com>
> > Date: Sat, 22 Mar 2008 15:36:06 +0300
> > Cc: gdb-patches@sources.redhat.com
> >
> > > What will happen after your patch if there's also a variable i_
> > > in the selected frame?
> >
> > The i_ in the breakpoint condition will be associated with the
> > member variable, not with the variable with selected frame.
>
> That could surprise the user.  Is it possible to make an additional
> change to look for possible other interpretations of i_ which are
> currently in scope, and display a warning of some kind if such
> possibilities are found?

The current behaviour was around for some time, and my patch only
fixes one corner case that is not consistent with the existing 
behaviour.

To answer your question -- I'm not sure. I think it would be
wrong for parse_exp_1 -- which is passed explicit block, to
go around looking at other blocks it was not asked for. We probably
can get block of selected frame, call parse_exp_1 again, in that block,
and then walk over two parse results, reporting variables which are
bound to different blocks. This sounds like some
substantial amount of work, though.

- Volodya


  reply	other threads:[~2008-03-22 13:20 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-22  9:40 Vladimir Prus
2008-03-22 12:07 ` Eli Zaretskii
2008-03-22 12:36   ` Vladimir Prus
2008-03-22 12:56     ` Eli Zaretskii
2008-03-22 13:20       ` Vladimir Prus [this message]
2008-03-22 14:49       ` Daniel Jacobowitz
2008-03-22 17:14         ` Eli Zaretskii
2008-03-24 18:05           ` Michael Snyder
2008-03-24 20:18             ` Eli Zaretskii
2008-03-24 21:04               ` Michael Snyder
2008-04-01 14:10 ` Daniel Jacobowitz
2008-04-03 12:51   ` Vladimir Prus
2008-04-03 13:33     ` Daniel Jacobowitz

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=200803221620.10176.vladimir@codesourcery.com \
    --to=vladimir@codesourcery.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sources.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