diff options
author | Aleksandr Platonov <platonov.aleksandr@huawei.com> | 2020-07-30 12:45:07 +0300 |
---|---|---|
committer | Aleksandr Platonov <platonov.aleksandr@huawei.com> | 2020-07-30 12:45:58 +0300 |
commit | 05b173466142596b3297ab02e423574cb74b3799 (patch) | |
tree | 9f5da85c351ed8df6966cb04c6fffca94deb5bd7 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp | |
parent | 3da6a974db86ba7d1f9a17a1e229daeade52a038 (diff) | |
download | llvm-05b173466142596b3297ab02e423574cb74b3799.zip llvm-05b173466142596b3297ab02e423574cb74b3799.tar.gz llvm-05b173466142596b3297ab02e423574cb74b3799.tar.bz2 |
[clangd] findNearbyIdentifier(): fix the word search in the token stream.
Without this patch the word occurrence search always returns the first token of the file.
Despite of that, `findNeardyIdentifier()` returns the correct result (but inefficently) until there are several matched tokens with the same value `floor(log2(<token line> - <word line>))` (e.g. several matched tokens on the same line).
Reviewed By: kadircet
Differential Revision: https://reviews.llvm.org/D84912
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
0 files changed, 0 insertions, 0 deletions