aboutsummaryrefslogtreecommitdiff
path: root/gdb/dbxread.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-05-21 00:15:12 -0600
committerTom Tromey <tom@tromey.com>2018-07-20 09:42:42 -0600
commit3c65e5b31cb5587773deff979099435b9687a0f4 (patch)
treeb13e4e32406f0d0ef00600828133d4b564f7f7df /gdb/dbxread.c
parenta60f3166aa946336c68e7a873d5eed6061b5733c (diff)
downloadgdb-3c65e5b31cb5587773deff979099435b9687a0f4.zip
gdb-3c65e5b31cb5587773deff979099435b9687a0f4.tar.gz
gdb-3c65e5b31cb5587773deff979099435b9687a0f4.tar.bz2
Move current_subfile to buildsym_compunit
This moves the global current_subfile into buildsym_compunit. gdb/ChangeLog 2018-07-20 Tom Tromey <tom@tromey.com> * xcoffread.c (process_linenos): Update. * stabsread.c (define_symbol, read_type, read_enum_type): Update. * mdebugread.c (psymtab_to_symtab_1): Update. * dwarf2read.c (setup_type_unit_groups) (lnp_state_machine::handle_set_file, dwarf_record_line_p) (lnp_state_machine::record_line, dwarf_decode_lines): Update. * dbxread.c (process_one_symbol): Update. * coffread.c (coff_symtab_read, enter_linenos) (process_coff_symbol): Update. * buildsym.h (current_subfile): Don't declare. (get_current_subfile): Declare. * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New member. (start_subfile, free_buildsym_compunit, push_subfile) (prepare_for_building, start_symtab): Update. (get_current_subfile): New function.
Diffstat (limited to 'gdb/dbxread.c')
-rw-r--r--gdb/dbxread.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/dbxread.c b/gdb/dbxread.c
index ad3f2a9..b5cec28 100644
--- a/gdb/dbxread.c
+++ b/gdb/dbxread.c
@@ -2508,7 +2508,7 @@ process_one_symbol (int type, int desc, CORE_ADDR valu, const char *name,
{
CORE_ADDR addr = last_function_start + valu;
- record_line (current_subfile, 0,
+ record_line (get_current_subfile (), 0,
gdbarch_addr_bits_remove (gdbarch, addr));
}
@@ -2642,7 +2642,7 @@ process_one_symbol (int type, int desc, CORE_ADDR valu, const char *name,
name. Patch things up. */
if (previous_stab_code == (unsigned char) N_SO)
{
- patch_subfile_names (current_subfile, name);
+ patch_subfile_names (get_current_subfile (), name);
break; /* Ignore repeated SOs. */
}
end_symtab (valu, SECT_OFF_TEXT (objfile));
@@ -2712,12 +2712,12 @@ process_one_symbol (int type, int desc, CORE_ADDR valu, const char *name,
CORE_ADDR addr = processing_gcc_compilation == 2 ?
last_function_start : valu;
- record_line (current_subfile, desc,
+ record_line (get_current_subfile (), desc,
gdbarch_addr_bits_remove (gdbarch, addr));
sline_found_in_function = 1;
}
else
- record_line (current_subfile, desc,
+ record_line (get_current_subfile (), desc,
gdbarch_addr_bits_remove (gdbarch, valu));
break;