diff options
author | Tom Tromey <tromey@redhat.com> | 2013-12-30 20:05:34 -0700 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2014-01-15 12:06:04 -0700 |
commit | 9e6c82ad4f55d0ff125721b94fa2191f1cc1000a (patch) | |
tree | 12ef5dcf38f7ae24931ee1f2cf541cb4dc476775 /gdb/dwarf2read.c | |
parent | 6ef55de768d4ab9065bc92aa00d828212c4af4f0 (diff) | |
download | binutils-9e6c82ad4f55d0ff125721b94fa2191f1cc1000a.zip binutils-9e6c82ad4f55d0ff125721b94fa2191f1cc1000a.tar.gz binutils-9e6c82ad4f55d0ff125721b94fa2191f1cc1000a.tar.bz2 |
make language_of_main static
This makes the global language_of_main static. Now it can be set only
via a new argument to set_main_name.
2014-01-15 Tom Tromey <tromey@redhat.com>
* dbxread.c (process_one_symbol): Update.
* dwarf2read.c (read_partial_die): Update.
* symfile.c (set_initial_language): Call main_language.
* symtab.c (language_of_main): Now static.
(set_main_name): Add 'lang' parameter.
(find_main_name): Update.
(main_language): New function.
(symtab_observer_executable_changed): Update.
* symtab.h (set_main_name): Update.
(language_of_main): Remove.
(main_language): Declare.
Diffstat (limited to 'gdb/dwarf2read.c')
-rw-r--r-- | gdb/dwarf2read.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index 609698b..0c3d16c 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -15322,13 +15322,7 @@ read_partial_die (const struct die_reader_specs *reader, practice. */ if (DW_UNSND (&attr) == DW_CC_program && cu->language == language_fortran) - { - set_main_name (part_die->name); - - /* As this DIE has a static linkage the name would be difficult - to look up later. */ - language_of_main = language_fortran; - } + set_main_name (part_die->name, language_fortran); break; case DW_AT_inline: if (DW_UNSND (&attr) == DW_INL_inlined |