Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: mec.gnu@mindspring.com
To: lsr@vinci.inesc-id.pt
Cc: gdb@sources.redhat.com
Subject: Re: gdb calls bypassbreakpoints
Date: Sat, 24 Jul 2004 07:53:00 -0000	[thread overview]
Message-ID: <410178E9.nail3NY14VXRW@mindspring.com> (raw)
In-Reply-To: <A0F93804-DCAD-11D8-B1A4-000A957774FE@algos.inesc-id.pt>

> Is there a way to stop this behavior and make gdb act as if the call 
> had came from the C file?

Well, no.  When gdb hits a breakpoint in your program, it has to
discard the state information and just get back to the top level
of the interpreter.

That is, if you do this:

  (gdb) break foo
  (gdb) break bar
  (gdb) print foo() + bar()

Then when gdb hits the breakpoint in foo(), it's going to forget
that it was in the middle of evaluating "foo() + bar()".
gdb will continue evaluating foo(), and when that is done,
gdb will ask for more commands and not continue with the
"+ bar()" part.

Michael C
GDB QA Guy


  reply	other threads:[~2004-07-23 20:44 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-23 15:05 Luís Russo
2004-07-24  7:53 ` mec.gnu [this message]
2004-07-25  0:03   ` Eli Zaretskii
2004-07-26 21:21 ` Andrew Cagney

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=410178E9.nail3NY14VXRW@mindspring.com \
    --to=mec.gnu@mindspring.com \
    --cc=gdb@sources.redhat.com \
    --cc=lsr@vinci.inesc-id.pt \
    /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