summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHaojian Wu <hokein@google.com>2018-11-12 16:03:59 +0000
committerHaojian Wu <hokein@google.com>2018-11-12 16:03:59 +0000
commit62fb2a216e66f518760eaf6c65f79b63a2dd2992 (patch)
treebd27d27250b0a931ead42976252f743760115275
parent6b3d33e99677aa80fa2a899902323b0e6c7e3762 (diff)
downloadbcm5719-llvm-62fb2a216e66f518760eaf6c65f79b63a2dd2992.tar.gz
bcm5719-llvm-62fb2a216e66f518760eaf6c65f79b63a2dd2992.zip
[clangd] Allow symbols from AnyScope in dexp.
Summary: We should allow symbols from any scope in dexp results, othewise `find StringRef` doesn't return any results (llvm::StringRef). Reviewers: ioeric Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, cfe-commits Differential Revision: https://reviews.llvm.org/D54427 llvm-svn: 346666
-rw-r--r--clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp b/clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp
index 8c7aabe4606..25ff4435364 100644
--- a/clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp
+++ b/clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp
@@ -139,6 +139,7 @@ class FuzzyFind : public Command {
StringRef(this->Scopes).split(Scopes, ',');
Request.Scopes = {Scopes.begin(), Scopes.end()};
}
+ Request.AnyScope = Request.Scopes.empty();
// FIXME(kbobyrev): Print symbol final scores to see the distribution.
static const auto OutputFormat = "{0,-4} | {1,-40} | {2,-25}\n";
outs() << formatv(OutputFormat, "Rank", "Symbol ID", "Symbol Name");
OpenPOWER on IntegriCloud