Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(561)

Unified Diff: tools/gn/ninja_binary_target_writer_unittest.cc

Issue 1544333002: Convert Pass()→std::move() in //tools (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/loader_unittest.cc ('k') | tools/gn/operators_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/ninja_binary_target_writer_unittest.cc
diff --git a/tools/gn/ninja_binary_target_writer_unittest.cc b/tools/gn/ninja_binary_target_writer_unittest.cc
index b9c50b7e168d13948a905f67d55c6a52cd954fb9..dc9c8ddf4373aab3b83a210ee97775e872d7d0e0 100644
--- a/tools/gn/ninja_binary_target_writer_unittest.cc
+++ b/tools/gn/ninja_binary_target_writer_unittest.cc
@@ -2,10 +2,12 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "tools/gn/ninja_binary_target_writer.h"
+
#include <sstream>
+#include <utility>
#include "testing/gtest/include/gtest/gtest.h"
-#include "tools/gn/ninja_binary_target_writer.h"
#include "tools/gn/scheduler.h"
#include "tools/gn/target.h"
#include "tools/gn/test_with_scope.h"
@@ -485,7 +487,7 @@ TEST(NinjaBinaryTargetWriter, WinPrecompiledHeaders) {
cxx_tool->set_outputs(SubstitutionList::MakeForTest(
"{{source_out_dir}}/{{target_output_name}}.{{source_name_part}}.o"));
cxx_tool->set_precompiled_header_type(Tool::PCH_MSVC);
- pch_toolchain.SetTool(Toolchain::TYPE_CXX, cxx_tool.Pass());
+ pch_toolchain.SetTool(Toolchain::TYPE_CXX, std::move(cxx_tool));
// Add a C compiler as well.
scoped_ptr<Tool> cc_tool(new Tool);
@@ -496,7 +498,7 @@ TEST(NinjaBinaryTargetWriter, WinPrecompiledHeaders) {
cc_tool->set_outputs(SubstitutionList::MakeForTest(
"{{source_out_dir}}/{{target_output_name}}.{{source_name_part}}.o"));
cc_tool->set_precompiled_header_type(Tool::PCH_MSVC);
- pch_toolchain.SetTool(Toolchain::TYPE_CC, cc_tool.Pass());
+ pch_toolchain.SetTool(Toolchain::TYPE_CC, std::move(cc_tool));
pch_toolchain.ToolchainSetupComplete();
// This target doesn't specify precompiled headers.
@@ -613,7 +615,7 @@ TEST(NinjaBinaryTargetWriter, GCCPrecompiledHeaders) {
cxx_tool->set_outputs(SubstitutionList::MakeForTest(
"{{source_out_dir}}/{{target_output_name}}.{{source_name_part}}.o"));
cxx_tool->set_precompiled_header_type(Tool::PCH_GCC);
- pch_toolchain.SetTool(Toolchain::TYPE_CXX, cxx_tool.Pass());
+ pch_toolchain.SetTool(Toolchain::TYPE_CXX, std::move(cxx_tool));
pch_toolchain.ToolchainSetupComplete();
// Add a C compiler as well.
@@ -625,7 +627,7 @@ TEST(NinjaBinaryTargetWriter, GCCPrecompiledHeaders) {
cc_tool->set_outputs(SubstitutionList::MakeForTest(
"{{source_out_dir}}/{{target_output_name}}.{{source_name_part}}.o"));
cc_tool->set_precompiled_header_type(Tool::PCH_GCC);
- pch_toolchain.SetTool(Toolchain::TYPE_CC, cc_tool.Pass());
+ pch_toolchain.SetTool(Toolchain::TYPE_CC, std::move(cc_tool));
pch_toolchain.ToolchainSetupComplete();
// This target doesn't specify precompiled headers.
« no previous file with comments | « tools/gn/loader_unittest.cc ('k') | tools/gn/operators_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698