summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2019-01-14 22:41:00 +0000
committerZachary Turner <zturner@google.com>2019-01-14 22:41:00 +0000
commitc0a246afbe03b8f1d52e06267e9c2a5f2c4521ff (patch)
tree47743cc3bc117058ce7d9a4160087db952d28897 /lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
parentffc1b8fd7653cdc61440bc0be5d3735146dd5015 (diff)
downloadbcm5719-llvm-c0a246afbe03b8f1d52e06267e9c2a5f2c4521ff.tar.gz
bcm5719-llvm-c0a246afbe03b8f1d52e06267e9c2a5f2c4521ff.zip
[SymbolFile] Remove the SymbolContext parameter from FindNamespace.
Every callsite was passing an empty SymbolContext, so this parameter had no effect. Inside the DWARF implementation of this function, however, there was one codepath that checked members of the SymbolContext. Since no call-sites actually ever used this functionality, it was essentially dead code, so I've deleted this code path as well. llvm-svn: 351132
Diffstat (limited to 'lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp')
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp16
1 files changed, 4 insertions, 12 deletions
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
index 48677102a49..2e9b6c012eb 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
@@ -1221,23 +1221,15 @@ uint32_t SymbolFileDWARFDebugMap::FindTypes(
//}
CompilerDeclContext SymbolFileDWARFDebugMap::FindNamespace(
- const lldb_private::SymbolContext &sc,
const lldb_private::ConstString &name,
const CompilerDeclContext *parent_decl_ctx) {
CompilerDeclContext matching_namespace;
- SymbolFileDWARF *oso_dwarf;
- if (sc.comp_unit) {
- oso_dwarf = GetSymbolFile(sc);
- if (oso_dwarf)
- matching_namespace = oso_dwarf->FindNamespace(sc, name, parent_decl_ctx);
- } else {
- ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
- matching_namespace = oso_dwarf->FindNamespace(sc, name, parent_decl_ctx);
+ ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
+ matching_namespace = oso_dwarf->FindNamespace(name, parent_decl_ctx);
- return (bool)matching_namespace;
- });
- }
+ return (bool)matching_namespace;
+ });
return matching_namespace;
}
OpenPOWER on IntegriCloud