[PATCH] D50517: [clangd] Generate incomplete trigrams for the Dex index

Kirill Bobyrev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Aug 10 01:48:23 PDT 2018


kbobyrev updated this revision to Diff 160071.
kbobyrev added a comment.

Complete the tests, finish the implementation.

One thought about prefix match suggestion: we should either make it more explicit for the index (e.g. introduce `prefixMatch` and dispatch `fuzzyMatch` to prefix matching in case query only contains one "true" symbol) or document this properly. While, as I wrote earlier, I totally support the idea of prefix matching queries of length 1 it might not align with some user expectations and it's also very implicit if we just generate tokens this way and don't mention it anywhere in the `DexIndex` implementation.

@ioeric, @ilya-biryukov any thoughts?


https://reviews.llvm.org/D50517

Files:
  clang-tools-extra/clangd/index/dex/Trigram.cpp
  clang-tools-extra/clangd/index/dex/Trigram.h
  clang-tools-extra/unittests/clangd/DexIndexTests.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50517.160071.patch
Type: text/x-patch
Size: 11393 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180810/9dc15cf4/attachment-0001.bin>


More information about the cfe-commits mailing list