[PATCH] D72746: [clangd] Add a flag for implicit references in the Index

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 15 03:33:34 PST 2020


kadircet added inline comments.


================
Comment at: clang-tools-extra/clangd/index/Ref.h:36
+  // one below.
+  Implicit = 1 << 3,
+  All = Declaration | Definition | Reference | Implicit,
----------------
kadircet wrote:
> instead of doing that, could we rather de-couple two enums completely and have a `symbolRoleToRefKind`(and vice-versa) method instead(we already have some customization in `toRefKind` now) ?
> 
> as current change increases the risk of overlapping in future(e.g. someone might change symbolrole::declaration and cause failures/regressions in clangd)
note that this would also require a bump to version of `on-disk` index in clangd/index/Serialization.cpp, as old information regarding `RefKind` won't be usable anymore.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D72746/new/

https://reviews.llvm.org/D72746





More information about the cfe-commits mailing list