[Lldb-commits] [PATCH] D150589: [lldb][DWARFASTParserClang][NFC] Simplify unnamed bitfield condition
Michael Buch via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Tue May 16 03:18:27 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rGca64f9af0447: [lldb][DWARFASTParserClang][NFC] Simplify unnamed bitfield condition (authored by Michael137).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150589/new/
https://reviews.llvm.org/D150589
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
@@ -2880,9 +2880,8 @@
if (detect_unnamed_bitfields) {
std::optional<FieldInfo> unnamed_field_info;
- uint64_t last_field_end = 0;
-
- last_field_end = last_field_info.bit_offset + last_field_info.bit_size;
+ uint64_t last_field_end =
+ last_field_info.bit_offset + last_field_info.bit_size;
if (!last_field_info.IsBitfield()) {
// The last field was not a bit-field...
@@ -2902,10 +2901,8 @@
// indeed an unnamed bit-field. We currently do not have the
// machinary to track the offset of the last field of classes we
// have seen before, so we are not handling this case.
- if (this_field_info.bit_offset != last_field_end &&
- this_field_info.bit_offset > last_field_end &&
- !(last_field_info.bit_offset == 0 &&
- last_field_info.bit_size == 0 &&
+ if (this_field_info.bit_offset > last_field_end &&
+ !(last_field_info.bit_offset == 0 && last_field_info.bit_size == 0 &&
layout_info.base_offsets.size() != 0)) {
unnamed_field_info = FieldInfo{};
unnamed_field_info->bit_size =
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D150589.522519.patch
Type: text/x-patch
Size: 1403 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20230516/6143b8aa/attachment-0001.bin>
More information about the lldb-commits
mailing list