[PATCH] D42942: [clangd] Collect definitions when indexing.

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 9 01:14:10 PST 2018


hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.

LGTM.



================
Comment at: clangd/index/Index.h:129
   //
-  // A C++ symbol could have multiple declarations and one definition (e.g.
-  // a function is declared in ".h" file, and is defined in ".cc" file).
-  //   * For classes, the canonical declaration is usually definition.
-  //   * For non-inline functions, the canonical declaration is a declaration
-  //     (not a definition), which is usually declared in ".h" file.
+  // A C++ symbol may have mulitple declarations, and we pick one to prefer.
+  //   * For classes, the canonical declaration should be the definition.
----------------
a typo here? `multiple`?


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D42942





More information about the cfe-commits mailing list