[lldb/DWARF] Replace C style casts with static_cast<> (NFC)
Using static_cast instead of C style casts better conveys the code's intent, is a tad more safe and stands out more.
This commit is contained in:
parent
3c88489a06
commit
226d52b1fa
|
|
@ -3638,9 +3638,9 @@ bool DWARFASTParserClang::CopyUniqueClassMethodTypes(
|
|||
}
|
||||
|
||||
DWARFASTParserClang *src_dwarf_ast_parser =
|
||||
(DWARFASTParserClang *)SymbolFileDWARF::GetDWARFParser(*src_die.GetCU());
|
||||
static_cast<DWARFASTParserClang *>(SymbolFileDWARF::GetDWARFParser(*src_die.GetCU()));
|
||||
DWARFASTParserClang *dst_dwarf_ast_parser =
|
||||
(DWARFASTParserClang *)SymbolFileDWARF::GetDWARFParser(*dst_die.GetCU());
|
||||
static_cast<DWARFASTParserClang *>(SymbolFileDWARF::GetDWARFParser(*dst_die.GetCU()));
|
||||
|
||||
// Now do the work of linking the DeclContexts and Types.
|
||||
if (fast_path) {
|
||||
|
|
|
|||
|
|
@ -3867,7 +3867,7 @@ SymbolFileDWARFDebugMap *SymbolFileDWARF::GetDebugMapSymfile() {
|
|||
lldb::ModuleSP module_sp(m_debug_map_module_wp.lock());
|
||||
if (module_sp) {
|
||||
m_debug_map_symfile =
|
||||
(SymbolFileDWARFDebugMap *)module_sp->GetSymbolFile();
|
||||
static_cast<SymbolFileDWARFDebugMap *>(module_sp->GetSymbolFile());
|
||||
}
|
||||
}
|
||||
return m_debug_map_symfile;
|
||||
|
|
|
|||
|
|
@ -529,7 +529,7 @@ SymbolFileDWARF *
|
|||
SymbolFileDWARFDebugMap::GetSymbolFileAsSymbolFileDWARF(SymbolFile *sym_file) {
|
||||
if (sym_file &&
|
||||
sym_file->GetPluginName() == SymbolFileDWARF::GetPluginNameStatic())
|
||||
return (SymbolFileDWARF *)sym_file;
|
||||
return static_cast<SymbolFileDWARF *>(sym_file);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue