Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [RFC] Fix comment for la_store_sym_names_in_linkage_form_p
@ 2019-06-13 13:50 Tom de Vries
  2019-06-13 15:28 ` Tom Tromey
  0 siblings, 1 reply; 2+ messages in thread
From: Tom de Vries @ 2019-06-13 13:50 UTC (permalink / raw)
  To: gdb-patches, Pedro Alves, Tom Tromey, Joel Brobecker

[-- Attachment #1: Type: text/plain, Size: 554 bytes --]

Hi,

The comment in gdb/language.h for la_store_sym_names_in_linkage_form_p
states:
...
/* True if the symbols names should be stored in GDB's data structures
   for minimal/partial/full symbols using their linkage (aka mangled)
   form; false if the symbol names should be demangled first.
...

And for C++, la_store_sym_names_in_linkage_form_p is false.

However, AFAICT, while partial and full symbols are stored mangled,
minimal symbols are stored mangled.

This patch fixes the comment to reflect the actual situation.

Any comments?

Thanks,
- Tom

[-- Attachment #2: tmp.patch --]
[-- Type: text/x-patch, Size: 561 bytes --]

diff --git a/gdb/language.h b/gdb/language.h
index e7446efa07..f584a7e637 100644
--- a/gdb/language.h
+++ b/gdb/language.h
@@ -265,7 +265,7 @@ struct language_defn
     const char *la_name_of_this;
 
     /* True if the symbols names should be stored in GDB's data structures
-       for minimal/partial/full symbols using their linkage (aka mangled)
+       for partial/full symbols using their linkage (aka mangled)
        form; false if the symbol names should be demangled first.
 
        Most languages implement symbol lookup by comparing the demangled

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [RFC] Fix comment for la_store_sym_names_in_linkage_form_p
  2019-06-13 13:50 [RFC] Fix comment for la_store_sym_names_in_linkage_form_p Tom de Vries
@ 2019-06-13 15:28 ` Tom Tromey
  0 siblings, 0 replies; 2+ messages in thread
From: Tom Tromey @ 2019-06-13 15:28 UTC (permalink / raw)
  To: Tom de Vries; +Cc: gdb-patches, Pedro Alves, Tom Tromey, Joel Brobecker

>>>>> "Tom" == Tom de Vries <tdevries@suse.de> writes:

Tom> This patch fixes the comment to reflect the actual situation.

Tom> Any comments?

This is ok.  Thanks for doing this.

I saw that this field is only used in a single spot in dwarf2read.c.  So
it would also be fine, I think, to remove it entirely and just check the
languages there -- that's done all over dwarf2read.c already anyway.

This whole area of storing demangled names is a mess unfortunately.
It needs a big cleanup.

Tom


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-06-13 15:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-13 13:50 [RFC] Fix comment for la_store_sym_names_in_linkage_form_p Tom de Vries
2019-06-13 15:28 ` Tom Tromey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox