[PATCH] D81920: [clangd] Change FSProvider::getFileSystem to take CurrentWorkingDirectory
Sam McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jun 16 14:51:12 PDT 2020
sammccall added a comment.
Looks like an improvement but I don't like the `(".")` in various places.
Maybe make the param optional<StringRef> and don't cd if it's none?
I wouldn't give it a default arg though, the idea is to force a choice.
================
Comment at: clang-tools-extra/clangd/ClangdServer.cpp:187
+ Opts.ClangTidyOpts =
+ GetClangTidyOptions(*FSProvider.getFileSystem("."), File);
Opts.SuggestMissingIncludes = SuggestMissingIncludes;
----------------
Not sure what to do in this patch, but ultimately I don't think we must/should pass an FS of any form into this callback.
(Doesn't make sense to assume getting options needs the FS, embedders can use the context to know what version of the FS to use if needed)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81920/new/
https://reviews.llvm.org/D81920
More information about the cfe-commits
mailing list