[Lldb-commits] [PATCH] D92643: [lldb] Lookup static const members in FindGlobalVariables

Andy Yankovsky via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Dec 4 02:25:10 PST 2020


werat created this revision.
werat requested review of this revision.
Herald added a reviewer: jdoerfert.
Herald added subscribers: lldb-commits, sstefan1.
Herald added a project: LLDB.

Static const members initialized inside a class definition might not have a corresponding DW_TAG_variable, so they're not indexed by ManualDWARFIndex.

Add an additional lookup in FindGlobalVariables. Try looking up the enclosing type (e.g. `foo::bar` for `foo::bar::A`) and then searching for a static const member (`A`) within this type.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D92643

Files:
  lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
  lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h
  lldb/test/API/python_api/target/globals/Makefile
  lldb/test/API/python_api/target/globals/TestTargetGlobals.py
  lldb/test/API/python_api/target/globals/main.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D92643.309491.patch
Type: text/x-patch
Size: 8284 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20201204/2072e602/attachment.bin>


More information about the lldb-commits mailing list