This revision was automatically updated to reflect the committed changes.
Closed by commit rL299758: [clangd] Extract FsPath from file:// uri (authored
by krasimir).
Changed prior to commit:
https://reviews.llvm.org/D31401?vs=94271&id=94507#toc
Repository:
rL LLVM
https://reviews.llvm.org/D
stanionascu marked 2 inline comments as done.
stanionascu added a comment.
Thank you for the review!
If there are no other comments/suggestions, would be great if someone would
merge it as I'm lacking the permission to do so.
https://reviews.llvm.org/D31401
_
krasimir accepted this revision.
krasimir added a comment.
This revision is now accepted and ready to land.
Looks good!
https://reviews.llvm.org/D31401
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/lis
stanionascu marked 5 inline comments as done.
stanionascu added inline comments.
Comment at: clangd/Protocol.cpp:61
if (KeyValue == "uri") {
- Result.uri = Value->getValue(Storage);
+ Result.uri = Uri::parse(Value->getValue(Storage));
} else if (KeyValue == "v
stanionascu updated this revision to Diff 94271.
stanionascu added a comment.
Refactored URI handling to make it more explicit, also updated the parts which
expect a File parameter and not an URI.
https://reviews.llvm.org/D31401
Files:
clangd/ASTManager.cpp
clangd/ASTManager.h
clangd/Doc
krasimir added inline comments.
Comment at: clangd/ASTManager.cpp:166
tooling::CompilationDatabase *
ASTManager::getOrCreateCompilationDatabaseForFile(StringRef Uri) {
auto &I = CompilationDatabases[Uri];
I think we should rename the `Uri` parameter here to
stanionascu created this revision.
rfc8089#appendix-E.2 specifies that paths can begin with a drive letter e.g. as
file:///c:/.
In this case just consuming front file:// is not enough and the 3rd slash must
be consumed to produce a valid path on windows.
The patch introduce a generic way of con