[PATCH] D50970: [clangd] Implement BOOST iterator
Ilya Biryukov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 22 03:19:54 PDT 2018
ilya-biryukov added a comment.
Summarizing the offline discussion with @kbobyrev, @ioeric and @sammccall in two comments.
================
Comment at: clang-tools-extra/clangd/index/dex/Iterator.h:96
+ /// shouldn't apply any boosting to the consumed item.
+ virtual float boost(DocID ID) const = 0;
----------------
With limit iterator in mind, let's rename this to `consume()` and make it non-const.
================
Comment at: clang-tools-extra/clangd/index/dex/Iterator.h:137
+/// and BOOST iterators are actually present in the query.
+std::vector<std::pair<DocID, float>>
+consumeAndBoost(Iterator &It,
----------------
Let's remove this function and change the interface of consume to return a vector of pairs instead.
https://reviews.llvm.org/D50970
More information about the cfe-commits
mailing list