Normalize paths on Windows#73
Closed
Riatre wants to merge 5 commits into
Closed
Conversation
…mprove CXXDestructor CXXConversion spell
1. Normalize paths in LSP document URIs and project root to forward slash and uppercase drive letters. 2. Normalize paths in compile_commands.json to forward slash and uppercase drive letters. 3. Normalize paths from directory listing to forward slash. (Drive letter should be same as input dir path, which is already uppercase since path of project root dir is normalized) 4. Add llvm::sys::path::convert_to_slash after certain llvm::sys::path and llvm::fs calls.
Contributor
Author
|
Note that this does not address emacs-lsp/emacs-ccls#10 (comment). |
9ce714d to
7e9097e
Compare
Owner
|
Manually cherry picked.. Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Generally, we have three sources of path strings:
Path strings from these three sources may have different slash (forward/backward) and drive letter (lowercase/uppercase) styles, as we use file path as map key, we have to normalize them.
Slashes will be converted to forward slash (
'/'), drive letters will be converted to uppercase (On Windows, it is guaranteed to be case insensitive).