Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang-tools-extra/clangd/refactor/Rename.cpp | ||
---|---|---|
124 | nit: not sure we need a separate section for these, I can imagine at most keyword/conflict/shadow | |
215 | nit: either "reserved [word|identifier|name]" or "keyword", but not both This could be friendlier, what about "the chosen name is a keyword"? | |
479 | Now that prepareRename only exposes ranges rather than edits, do we still need this empty special case, or can we go back to using "clangd_rename_dummy" or so? (Sorry for the back and forth here) |
clang-tools-extra/clangd/refactor/Rename.cpp | ||
---|---|---|
124 | yeah, I would leave it as-is for now. we could factor this out when there are more. | |
479 | oh, you're right. And the documentation of the prepareRename is stale. Updated. A slight concern of using a dummy name is that it may cause a name validation, but it should rarely happen if we choose some name like clangd_rename_dummy. |
clang-tools-extra/clangd/ClangdServer.cpp | ||
---|---|---|
416 | oh, reserved name is clever :-) Though it occurs to me - we could actually warn on rename to a reserved name! |
clang-tools-extra/clangd/ClangdServer.cpp | ||
---|---|---|
416 | giving a warning is nice, it seems too strict to forbidden users (library developers)) renaming a symbol to __a . The code is still compilable after all. |
oh, reserved name is clever :-)
Though it occurs to me - we could actually warn on rename to a reserved name!
(We can still do this and just ignore __clangd_*)