-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Renaming will fail under certain circumstances #687
Comments
I'm not able to reproduce this. I'm testing with clangd 18, but on Linux rather than Windows. In the log, I can see that the duplicate edits appear under two different files which differ only by case. One is So I think this is some sort of Windows-specific issue related to case-insensitive file systems. |
@HighCommander4 |
I think a proper fix to this is likely to be on the server side, something like clangd/clangd#108. That said, the issue may be avoidable with proper configuration. If you share a complete log (starting from clangd startup) that might contain some clues. |
@HighCommander4 |
To elaborate a bit on what I mean by this: sometimes, the problem stems from an inconsistency in the |
@HighCommander4
|
What I'm seeing in the log, is that vscode is sending a lowercase Since you probably can't control what vscode sends, I would try changing the |
@HighCommander4 |
I encountered the exact same problem. Could you please share how you ultimately resolved it? Thank you very much. |
@samuelyhsu |
I encountered this problem on Windows 10, and fix it by change all 'E:' into 'e:' in compile_commands.json generated by cmake(E: is the location of my project). my reproduce:
vscode info: clangd extension version: v0.1.29 |
Steps to reproduce
Description
This issue seems to have come up a long time ago, not a recent update. When renaming failed in the past I always thought it was because the extension wasn't powerful enough until one time I previewed renaming.
I came up with a temporary solution by adding the following code inside the {} of 'middleware' in the 'clangd-context.ts' file.
Logs
System information
The text was updated successfully, but these errors were encountered: