Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Michael Elizabeth Chastain <mec@shout.net>
To: drow@mvista.com, gdb-patches@sources.redhat.com
Subject: Re: [RFA] Select a particular mangling of a demangled symbol in lookup_block_symbol
Date: Fri, 15 Feb 2002 16:38:00 -0000	[thread overview]
Message-ID: <200202160038.g1G0cbd03065@duracef.shout.net> (raw)

Hi Daniel,

> What we really SHOULD do is set it on both constructors silently, without
> even acknowledging that they are different functions, or else offer the user
> the choice.  My preference is actually for the former.

There's more grossness than that.  Suppose that the constructor calls
another function foo().  Suppose the user sets a breakpoint on foo()
and looks at the stack and sees the constructor.  Suppose the user looks
at the assembly code for the constructor.  Suppose the user continues,
and takes the breakpoint on foo() again, and disassembles the constructor
again, and sees different assembly code for the constructor.

Games like that impair the user's trust in gdb.  They start with a lie,
And they lead to endless scenarios where you have to fix things up in
order to maintain the lie.

I would prefer that the different blocks of object code with different
mangled names have different demangled names as well, such as "Foo::Foo()"
and "Foo::Foo$nic()".  (I guess if the user actually names one of his
member functions Foo$nic then we are screwed ... is there any possible
name which is not legal C++ member name?)

Michael C


             reply	other threads:[~2002-02-16  0:38 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-02-15 16:38 Michael Elizabeth Chastain [this message]
2002-02-15 16:46 ` Daniel Jacobowitz
  -- strict thread matches above, loose matches on Subject: below --
2002-02-16 10:59 Michael Elizabeth Chastain
2002-02-15 18:15 Michael Elizabeth Chastain
2002-02-14 15:55 Daniel Jacobowitz
2002-03-19 11:53 ` Daniel Jacobowitz
2002-03-19 14:25   ` Elena Zannoni
2002-03-19 14:20 ` Elena Zannoni
2002-03-19 14:47   ` Elena Zannoni
2002-03-22 10:55     ` Daniel Jacobowitz
2002-03-22 12:11       ` Elena Zannoni
2002-03-22 14:53         ` Daniel Jacobowitz
2002-03-22 10:52   ` Daniel Jacobowitz
2002-03-22 12:10     ` Elena Zannoni

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=200202160038.g1G0cbd03065@duracef.shout.net \
    --to=mec@shout.net \
    --cc=drow@mvista.com \
    --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