This is the mail archive of the
mailing list for the GDB project.
Re: Best way to work with settings that apply to a file (or dwarf cu)
- From: Daniel Jacobowitz <drow at false dot org>
- To: Joost van der Sluis <joost at cnoc dot nl>
- Cc: gdb at sourceware dot org
- Date: Sun, 16 Oct 2011 11:03:57 -0400
- Subject: Re: Best way to work with settings that apply to a file (or dwarf cu)
- References: <email@example.com>
On Wed, Oct 12, 2011 at 5:09 AM, Joost van der Sluis <firstname.lastname@example.org> wrote:
> On the other hand, I saw that this same problem also applies to the
> language of a symbol. But instead of querying the symtab for the
> language, the symbol has a field called language, which is set for each
> symbol within a compilation-unit. (For Dwarf)
> ie: all symbols do have a language setting. But for all symbols within
> one symtab this setting is the same. Wouldn't it be easier to add a link
> in each symbol to it's symtab, and store the language there? (This is
> what I tried to do for this specific pascal-flag)
IMO, it's going to be a lot easier if you make all you need available
in the type. There's precedent for that in GDB.
There are a couple of reasons you don't want a type to symtab link -
for instance, handling of types which are duplicated across multiple
input files. We don't do that very well today, but we should.