[PATCH] D65263: [clangd] a prototype for triggering rename after extracting.
Ilya Biryukov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 31 01:32:18 PDT 2019
ilya-biryukov added a comment.
In D65263#1606371 <https://reviews.llvm.org/D65263#1606371>, @hokein wrote:
> I agree that doing rename after extraction is not an ideal approach (both correctness and latency), there should be other better ways to achieve this.
> However as a LSP server, we may want to align with the community and other language servers (typescript, java) in order to provide consistent refactoring experience across languages (vscode <https://code.visualstudio.com/docs/editor/refactoring> prefers to do extract with a default name and rename afterwards).
Java and Typescript can pretty much guarantee (local) rename is fast and latency is never an issue for those languages.
Either approach seems to require LSP extensions. Pre-select seems to provide better UX , that's the reason I'm proposing to look in that direction.
> Note that this patch aims to implement a generic mechanism to perform a chain of small refactorings (extract + rename is just one example), we still need this no match which way we're going to perform.
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
More information about the cfe-commits