This is an archive of the discontinued LLVM Phabricator instance.

[lldb] Consider TAG_imported_declaration in DebugNamesIndex
ClosedPublic

Authored by fdeazeve on Jul 7 2023, 10:58 AM.

Details

Summary

In order to recognize namespace aliases as a namespace, the
DW_TAG_imported_declaration has to be taken into account. The name of these DIEs
is already included in all accelerator tables as of D143397.

Two of the three Index classes already handle this correctly:

  1. ManualDWARFIndex (as of D143398)
  2. AppleDWARFIndex works by default with D143397, since apple has a table

dedicated to namespaces.

This commit updates the third index class, DWARF 5's DebugNamesDWARFIndex.
As a result, it fixes the following test with DWARF 5:
commands/expression/namespace-alias/TestInlineNamespaceAlias.py

Diff Detail

Event Timeline

fdeazeve created this revision.Jul 7 2023, 10:58 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 7 2023, 10:58 AM
Herald added a subscriber: arphaman. · View Herald Transcript
fdeazeve requested review of this revision.Jul 7 2023, 10:58 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 7 2023, 10:58 AM
Michael137 accepted this revision.Jul 7 2023, 11:18 AM

LGTM, thanks!

This revision is now accepted and ready to land.Jul 7 2023, 11:18 AM