[Lldb-commits] [PATCH] D154513: [lldb][NFC] Factor out code from SymbolFileDWARF::ParseVariableDIE
Alex Langford via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Thu Jul 6 09:15:38 PDT 2023
bulbazord accepted this revision.
bulbazord added a comment.
This revision is now accepted and ready to land.
Makes sense to me. There are some potential improvements we could make to this code (which I'm sure you can already identify), but to keep this change relatively risk-free we should probably stick to just shifting things around. Thanks for doing this!
================
Comment at: lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp:3414-3420
+ DWARFExpressionList location_list = [&] {
+ if (location_form.IsValid())
+ return GetExprListFromAtLocation(location_form, module, die, func_low_pc);
+ if (const_value_form.IsValid())
+ return GetExprListFromAtConstValue(const_value_form, module, die);
+ return DWARFExpressionList(module, DWARFExpression(), die.GetCU());
+ }();
----------------
Not related to the review itself, but this makes me wish C++ had "if expressions" from Rust...
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D154513/new/
https://reviews.llvm.org/D154513
More information about the lldb-commits
mailing list