[PATCH] D70194: [clangd] Ignore more implicit nodes in computing selection.

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 14 00:05:48 PST 2019


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

LGTM, thanks!



================
Comment at: clang-tools-extra/clangd/Selection.cpp:162
+  // Refs to operator() and [] are (almost?) always implicit as part of calls.
+  if (auto *DRE = llvm::dyn_cast<DeclRefExpr>(S))
+    if (auto *FD = llvm::dyn_cast<FunctionDecl>(DRE->getDecl()))
----------------
nit: braces


================
Comment at: clang-tools-extra/clangd/Selection.cpp:163
+  if (auto *DRE = llvm::dyn_cast<DeclRefExpr>(S))
+    if (auto *FD = llvm::dyn_cast<FunctionDecl>(DRE->getDecl()))
+      switch (FD->getOverloadedOperator()) {
----------------
nit: braces


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D70194





More information about the cfe-commits mailing list