Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Daniel Berlin <dan@cgsoftware.com>
To: Benjamin Kosnik <bkoz@redhat.com>
Cc: Daniel Berlin <dan@cgsoftware.com>, gdb@sources.redhat.com
Subject: Re: can't find class named `foo', as given by C++ RTTI
Date: Thu, 28 Jun 2001 16:02:00 -0000	[thread overview]
Message-ID: <877kxwmcmi.fsf@cgsoftware.com> (raw)
In-Reply-To: <Pine.SOL.3.91.1010628012839.22816A-100000@taarna.cygnus.com>

Benjamin Kosnik <bkoz@redhat.com> writes:

>> We already rely on being able to get mangled names from debug info too
>> much.  This is why the clone constructors have the wrong name (they
>> end up being fred() instead of fred::fred()).  Their
>> specification has no DW_AT_MIPS_linkage_name, because it can't.  They
>> have no DW_AT_MIPS_linkage_name beause they shouldn't need to.
>> 
>> What really should be happening is that we should be generating
>> qualified names on our own, and ignoring DW_AT_MIPS_linkage_name
>> completely.
> 
> Ah. I get it now. So this namespace issue is probably the same problem that 
> nested types are having...
Yes.
Exactly.

It usually clicks once you realize that all those things named
"std::a::b::c::d" are really all in the same scope (not the global
scope, IIRC, I mean the ones appearing in each file are in that file's
file-level scope), and not in the scope named std::a::b::c.
I.E. It's all an illusion.
There is no spoon.

Nested classes and structs *might* have the right scope, it depends on
the sym reader.


> 
> I was wondering about the ctor issue.
> 
>> And we should be properly supporting namespaces, using directives,
>> etc, anyway.  It would also let us be able to support java packages
>> properly and whatnot.
> 
> These are all required features in gdb, not optional features,
> right?

Well, we could start by stop trying to put up the illusion 
> 
>> I can make gcc output this info in about a day.
> 
> Well then.
Patch submitted a little earlier to add support for at least
outputting namespaces (no importing the declarations into other
scopes).

This will give us the ability to make up the qualified names on our
own, at least.
> 
>> i've got a collection of references for symbol table
>> designs that can handle these things properly and efficiently, and
>> close enough to the existing basic symbol table structure that you
>> wouldn't have to start anywhere near from scratch, or come up with a
>> design on your own.
> 
> Might as well post the links or citations if you've got them handy.
Let me hunt it down, it's somewhere on my FS.

> 
> -benjamin

-- 
"I have a friend named Dennis.  Both of his parents were midgets,
but he isn't a midget.  He's a midget-dwarf.  He's two inches
tall.  He's the one who poses for trophies.
"-Steven Wright


  reply	other threads:[~2001-06-28 16:02 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-27 21:55 Benjamin Kosnik
2001-06-27 22:25 ` Daniel Berlin
2001-06-27 22:51   ` Benjamin Kosnik
2001-06-27 23:26     ` Daniel Berlin
2001-06-28  1:37       ` Benjamin Kosnik
2001-06-27 23:06   ` Daniel Berlin
2001-06-28  1:32     ` Benjamin Kosnik
2001-06-28 16:02       ` Daniel Berlin [this message]
2001-06-28 16:14         ` Benjamin Kosnik
2001-06-29 15:14     ` Jim Blandy
2001-06-29 23:43       ` Daniel Berlin
2001-06-30 10:14         ` Jim Blandy
2001-06-29 11:15 ` Jim Blandy
2001-06-29 11:20   ` Daniel Berlin
2001-06-29 11:34     ` Benjamin Kosnik
2001-06-29 11:38   ` Daniel Berlin

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=877kxwmcmi.fsf@cgsoftware.com \
    --to=dan@cgsoftware.com \
    --cc=bkoz@redhat.com \
    --cc=gdb@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