Depends on D81998
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang-tools-extra/clangd/ClangdServer.h | ||
---|---|---|
46 | Hmm, I like the idea of avoiding a custom type and just reusing the standard one here, but:
anything wrong with just std::function<ClangTidyOptions(StringRef)>? |
clang-tools-extra/clangd/tool/ClangdMain.cpp | ||
---|---|---|
495–498 | if (llvm::none_of(Sources, [](const auto &Source) { return Source.first.Checks.hasValue(); })) |
I'm of the idea that rather than having ClangdTidyOptionsProvider inherit form tidy::ClangTidyOptionsProvider, just have it as its own class. We don't need the interface offered by clang tidy here. It would solve the must be threadsafe comment issue as well as reduce the need for some unnecessary code in there.
Hmm, I like the idea of avoiding a custom type and just reusing the standard one here, but:
anything wrong with just std::function<ClangTidyOptions(StringRef)>?
It's reasonable to use a ClangTidyOptionsProvider to create them, though I'm not sure it actually saves anything.