diff options
| author | Benjamin Kramer <benny.kra@googlemail.com> | 2014-03-10 17:55:02 +0000 |
|---|---|---|
| committer | Benjamin Kramer <benny.kra@googlemail.com> | 2014-03-10 17:55:02 +0000 |
| commit | c81e2906c15fc34a1801624838daa0af3b2cab4c (patch) | |
| tree | fcfb9c88622f2b7bdc8f2f8dbce2e580c0ba2cee /lib/Tooling/CompilationDatabase.cpp | |
| parent | 15fd658d179dfa842e067e34d4442ead6b1e85e4 (diff) | |
| download | clang-c81e2906c15fc34a1801624838daa0af3b2cab4c.tar.gz clang-c81e2906c15fc34a1801624838daa0af3b2cab4c.tar.bz2 clang-c81e2906c15fc34a1801624838daa0af3b2cab4c.tar.xz | |
[C++11] Avoid implicit conversion of ArrayRef to std::vector and use move semantics where appropriate.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203477 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Tooling/CompilationDatabase.cpp')
| -rw-r--r-- | lib/Tooling/CompilationDatabase.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Tooling/CompilationDatabase.cpp b/lib/Tooling/CompilationDatabase.cpp index 57424e37e9..b513446a54 100644 --- a/lib/Tooling/CompilationDatabase.cpp +++ b/lib/Tooling/CompilationDatabase.cpp @@ -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> |
