[PATCH] D71598: [clangd] Filter implicit references from index while renaming
Kirill Bobyrev via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 17 04:06:58 PST 2019
kbobyrev created this revision.
kbobyrev added reviewers: ilya-biryukov, kadircet.
kbobyrev added a project: clang-tools-extra.
Herald added subscribers: usaxena95, arphaman, mgrang, jkorous, MaskRay.
When asked for references during cross-file rename, index might return implicit references to the renamed symbol (such as those in macro expansions). To fix the incorrect behavior, this patch introduces basic filtering machinery which ensures that all ranges where renaming is about to be applied actually contains the identifier the user asked to rename.
https://reviews.llvm.org/D71598
Files:
clang-tools-extra/clangd/SourceCode.cpp
clang-tools-extra/clangd/SourceCode.h
clang-tools-extra/clangd/refactor/Rename.cpp
clang-tools-extra/clangd/unittests/RenameTests.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D71598.234265.patch
Type: text/x-patch
Size: 6500 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191217/ea48c4c5/attachment.bin>
More information about the cfe-commits
mailing list