We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1fced7d commit 9934f15Copy full SHA for 9934f15
server/src/fetchers/FetcherUtils.cpp
@@ -57,6 +57,12 @@ void ClangToolRunner::run(const fs::path &file,
57
if (!Paths::isSourceFile(file) && (!Paths::isHeaderFile(file) || onlySource)) {
58
return;
59
}
60
+ if (onlySource) {
61
+ if (!CollectionUtils::contains(compilationDatabase->getAllFiles(), file)) {
62
+ throw CompilationDatabaseException(
63
+ "compile_commands.json doesn't contain a command for source file " + file.string());
64
+ }
65
66
auto clangTool = std::make_unique<clang::tooling::ClangTool>(
67
compilationDatabase->getClangCompilationDatabase(), file.string());
68
if (ignoreDiagnostics) {
0 commit comments