Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Joel Brobecker <brobecker@adacore.com>
Cc: Jerome Guitton <guitton@adacore.com>, gdb-patches@sources.redhat.com
Subject: Re: [RFA] backtrace in mixed language applications
Date: Wed, 15 Aug 2007 19:29:00 -0000	[thread overview]
Message-ID: <20070815192902.GA1422@caradoc.them.org> (raw)
In-Reply-To: <20070815191834.GK11498@adacore.com>

On Wed, Aug 15, 2007 at 12:18:34PM -0700, Joel Brobecker wrote:
> I think this opens the chance for the debugger to change the selected
> frame if something goes wrong (or the user presses controlC), which is an
> unexpected side-effect.

Correct.  If you have to switch the global selected frame, please use
a cleanup.  It's better to pass the selected frame explicitly where
possible, but it may not be practical depending what is checking the
language.

> Also, I'm thinking this is the wrong place for doing this frame switch.
> How about doing it inside print_frame? I think this would make sure
> we cover all the cases where we print a frame, such as after an "up",
> "down", or a "frame" command. And I think the frame selection needs
> to be protected against error raising.
> 
> What do others think?

Yes, I agree.  If we really need to change the selected frame to print
a frame correctly, then let's do it lower down (or document/assert
the requirement).

-- 
Daniel Jacobowitz
CodeSourcery


  reply	other threads:[~2007-08-15 19:29 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-10 10:03 Jerome Guitton
2007-08-15 19:14 ` Joel Brobecker
2007-08-15 19:29   ` Daniel Jacobowitz [this message]
2007-09-17 11:28 ` Jerome Guitton
2008-01-09 20:48 ` [RFA] backtrace in mixed language applications (take 2) Joel Brobecker
2008-01-29 18:06   ` Daniel Jacobowitz
2008-02-04 20:56     ` Joel Brobecker
2008-02-04 21:04       ` Joel Brobecker
2008-04-24  2:15         ` Joel Brobecker
2008-05-01 19:48           ` Daniel Jacobowitz
2008-05-07 11:36             ` Joel Brobecker

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=20070815192902.GA1422@caradoc.them.org \
    --to=drow@false.org \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=guitton@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