forked from OSchip/llvm-project
[clang] Use compile-command interpolation to provide commands for header files.
Summary: This uses the inferring wrapper introduced in D45006. Subscribers: klimek, ilya-biryukov, jkorous-apple, ioeric, cfe-commits Differential Revision: https://reviews.llvm.org/D45007 llvm-svn: 329582
This commit is contained in:
parent
4220f89107
commit
307c4837cc
|
@ -86,6 +86,8 @@ DirectoryBasedGlobalCompilationDatabase::getCDBInDirLocked(PathRef Dir) const {
|
|||
return CachedIt->second.get();
|
||||
std::string Error = "";
|
||||
auto CDB = tooling::CompilationDatabase::loadFromDirectory(Dir, Error);
|
||||
if (CDB)
|
||||
CDB = tooling::inferMissingCompileCommands(std::move(CDB));
|
||||
auto Result = CDB.get();
|
||||
CompilationDatabases.insert(std::make_pair(Dir, std::move(CDB)));
|
||||
return Result;
|
||||
|
|
Loading…
Reference in New Issue