[C++11] Avoid implicit conversion of ArrayRef to std::vector and use move semantics where appropriate.

llvm-svn: 203477
This commit is contained in:
Benjamin Kramer
2014-03-10 17:55:02 +00:00
parent e655754d57
commit 3f755aa7a8
8 changed files with 26 additions and 30 deletions

View File

@@ -303,7 +303,8 @@ FixedCompilationDatabase(Twine Directory, ArrayRef<std::string> CommandLine) {
std::vector<std::string> ToolCommandLine(1, "clang-tool");
ToolCommandLine.insert(ToolCommandLine.end(),
CommandLine.begin(), CommandLine.end());
CompileCommands.push_back(CompileCommand(Directory, ToolCommandLine));
CompileCommands.push_back(
CompileCommand(Directory, std::move(ToolCommandLine)));
}
std::vector<CompileCommand>