This is an archive of the discontinued LLVM Phabricator instance.

[clangd] Set SymbolID for sema macros so that they can be merged with index macros.
ClosedPublic

Authored by ioeric on Sep 5 2018, 9:23 AM.

Event Timeline

ioeric created this revision.Sep 5 2018, 9:23 AM
ioeric updated this revision to Diff 164055.Sep 5 2018, 9:29 AM
  • Set name for the test symbol.
sammccall accepted this revision.Sep 5 2018, 9:43 AM
sammccall added inline comments.
clangd/AST.h
41

maybe add a comment about the semantics of macro symbol IDs - particularly that they depend on the exact file offset.

We could change these semantics in future by reimplementing this function, there's no reason we have to use USRs for everything, and macros are really simple.

clangd/index/SymbolCollector.cpp
387–388

this is now dead

446–447

update this to use getSymbolID

This revision is now accepted and ready to land.Sep 5 2018, 9:43 AM
ioeric updated this revision to Diff 164177.Sep 6 2018, 2:58 AM
ioeric marked 2 inline comments as done.
  • improve comment; remove dead code.
This revision was automatically updated to reflect the committed changes.