[Lldb-commits] [PATCH] D150299: [lldb][NFCI] Redefine dw_attr_t typedef with llvm::dwarf::Attribute
Alex Langford via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Fri May 12 11:59:09 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rG64f1fda29e2d: [lldb][NFCI] Redefine dw_attr_t typedef with llvm::dwarf::Attribute (authored by bulbazord).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150299/new/
https://reviews.llvm.org/D150299
Files:
lldb/include/lldb/Core/dwarf.h
lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.cpp
lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp
lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp
Index: lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp
@@ -239,6 +239,8 @@
dw_attr_t attr = attributes.AttributeAtIndex(i);
DWARFFormValue form_value;
switch (attr) {
+ default:
+ break;
case DW_AT_name:
if (attributes.ExtractFormValueAtIndex(i, form_value))
name = form_value.AsCString();
Index: lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp
@@ -391,6 +391,8 @@
if (!attributes.ExtractFormValueAtIndex(i, form_value))
continue;
switch (attr) {
+ default:
+ break;
case DW_AT_loclists_base:
SetLoclistsBase(form_value.Unsigned());
break;
Index: lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/DWARFAbbreviationDeclaration.cpp
@@ -40,7 +40,7 @@
m_has_children = data.GetU8(offset_ptr);
while (data.ValidOffset(*offset_ptr)) {
- dw_attr_t attr = data.GetULEB128(offset_ptr);
+ auto attr = static_cast<dw_attr_t>(data.GetULEB128(offset_ptr));
auto form = static_cast<dw_form_t>(data.GetULEB128(offset_ptr));
// This is the last attribute for this abbrev decl, but there may still be
Index: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
@@ -274,6 +274,8 @@
if (!attributes.ExtractFormValueAtIndex(i, form_value))
continue;
switch (attr) {
+ default:
+ break;
case DW_AT_abstract_origin:
abstract_origin = form_value;
break;
Index: lldb/include/lldb/Core/dwarf.h
===================================================================
--- lldb/include/lldb/Core/dwarf.h
+++ lldb/include/lldb/Core/dwarf.h
@@ -21,7 +21,7 @@
}
}
-typedef uint16_t dw_attr_t;
+typedef llvm::dwarf::Attribute dw_attr_t;
typedef llvm::dwarf::Form dw_form_t;
typedef llvm::dwarf::Tag dw_tag_t;
typedef uint64_t dw_addr_t; // Dwarf address define that must be big enough for
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D150299.521752.patch
Type: text/x-patch
Size: 2642 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20230512/8ea05bec/attachment.bin>
More information about the lldb-commits
mailing list