siggi-alpheus created this revision.
siggi-alpheus added a reviewer: labath.
siggi-alpheus added a project: LLDB.
Herald added subscribers: JDevlieghere, arphaman.
Herald added a reviewer: shafik.
Herald added a project: All.
siggi-alpheus requested review of this revision.
Herald added a subscriber: lldb-commits.
See issue 55040 <https://github.com/llvm/llvm-project/issues/55040> where
static members of classes declared in the anonymous namespace are incorrectly
returned as member fields from lldb::SBType::GetFieldAtIndex(). It appears that
attrs.member_byte_offset contains a sentinel value for members that don't have
a DW_AT_data_member_location.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D124409
Files:
lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
Index: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
@@ -2669,7 +2669,7 @@
attrs.accessibility = eAccessNone;
// Handle static members
- if (attrs.is_external && attrs.member_byte_offset == UINT32_MAX) {
+ if (attrs.member_byte_offset == UINT32_MAX) {
Type *var_type = die.ResolveTypeUID(attrs.encoding_form.Reference());
if (var_type) {
Index: lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
===================================================================
--- lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
+++ lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
@@ -2669,7 +2669,7 @@
attrs.accessibility = eAccessNone;
// Handle static members
- if (attrs.is_external && attrs.member_byte_offset == UINT32_MAX) {
+ if (attrs.member_byte_offset == UINT32_MAX) {
Type *var_type = die.ResolveTypeUID(attrs.encoding_form.Reference());
if (var_type) {
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits