summaryrefslogtreecommitdiff
path: root/gdb/symfile.h
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2013-02-03 16:00:34 +0000
committerJan Kratochvil <jan.kratochvil@redhat.com>2013-02-03 16:00:34 +0000
commited4d9dacb69f998899d48d8d9678de87938da7d8 (patch)
tree78c6bfa6b2755787d1dbfa0827e992feb232cfe0 /gdb/symfile.h
parente6b3eacaca03f328175064c698a4542e96a63df7 (diff)
downloadgdb-ed4d9dacb69f998899d48d8d9678de87938da7d8.tar.gz
gdb/
Code cleanup. * breakpoint.c (clear_command): Remove variable is_abs, unify the call of filename_cmp with compare_filenames_for_search. * dwarf2read.c (dw2_map_symtabs_matching_filename): Remove variable is_abs, unify the call of FILENAME_CMP with compare_filenames_for_search. New gdb_asserts for real_path and name. Unify the call of compare_filenames_for_search with FILENAME_CMP. * psymtab.c (partial_map_symtabs_matching_filename): Likewise. * symfile.h (struct quick_symbol_functions): Extend the comment for map_symtabs_matching_filename. * symtab.c (compare_filenames_for_search): Remove the function comment relative path requirement. Handle absolute filenames, with a comment. (iterate_over_some_symtabs): Remove variable is_abs, unify the call of FILENAME_CMP with compare_filenames_for_search. New gdb_asserts for real_path and name. Unify the call of compare_filenames_for_search with FILENAME_CMP. (iterate_over_symtabs): New gdb_assert on REAL_PATH. gdb/testsuite/ * gdb.mi/mi-fullname-deleted.exp: Use double last slash for $srcfileabs. (compare_filenames_for_search does not match) (compare_filenames_for_search does match): New tests.
Diffstat (limited to 'gdb/symfile.h')
-rw-r--r--gdb/symfile.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/gdb/symfile.h b/gdb/symfile.h
index b70438e214e..aec21486b78 100644
--- a/gdb/symfile.h
+++ b/gdb/symfile.h
@@ -159,9 +159,10 @@ struct quick_symbol_functions
/* Expand and iterate over each "partial" symbol table in OBJFILE
where the source file is named NAME.
- If NAME is not absolute, a match after a '/' in the symbol
- table's file name will also work. REAL_PATH is the absolute file
- name run through gdb_realpath.
+ If NAME is not absolute, a match after a '/' in the symbol table's
+ file name will also work, REAL_PATH is NULL then. If NAME is
+ absolute then REAL_PATH is non-NULL absolute file name as resolved
+ via gdb_realpath from NAME.
If a match is found, the "partial" symbol table is expanded.
Then, this calls iterate_over_some_symtabs (or equivalent) over