forked from OSchip/llvm-project
Fix spurious output in JSONCompilationDatabase
llvm-svn: 172321
This commit is contained in:
parent
1737bd3a92
commit
3128a11ee8
|
@ -167,12 +167,8 @@ JSONCompilationDatabase::getCompileCommands(StringRef FilePath) const {
|
|||
std::string Error;
|
||||
llvm::raw_string_ostream ES(Error);
|
||||
StringRef Match = MatchTrie.findEquivalent(NativeFilePath.str(), ES);
|
||||
if (Match.empty()) {
|
||||
if (Error.empty())
|
||||
Error = "No match found.";
|
||||
llvm::outs() << Error << "\n";
|
||||
if (Match.empty())
|
||||
return std::vector<CompileCommand>();
|
||||
}
|
||||
llvm::StringMap< std::vector<CompileCommandRef> >::const_iterator
|
||||
CommandsRefI = IndexByFile.find(Match);
|
||||
if (CommandsRefI == IndexByFile.end())
|
||||
|
|
Loading…
Reference in New Issue