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

Unified Diff: chrome/test/chromedriver/chrome/devtools_client_impl.cc

Issue 1551503002: Convert Pass()→std::move() in //chrome (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
Index: chrome/test/chromedriver/chrome/devtools_client_impl.cc
diff --git a/chrome/test/chromedriver/chrome/devtools_client_impl.cc b/chrome/test/chromedriver/chrome/devtools_client_impl.cc
index a14c1c8c1a529c2a265f5fb36a24e9f7aab4ae1b..5d51e929c2dd3e7fbb96fa59db3686a3863be436 100644
--- a/chrome/test/chromedriver/chrome/devtools_client_impl.cc
+++ b/chrome/test/chromedriver/chrome/devtools_client_impl.cc
@@ -4,6 +4,8 @@
#include "chrome/test/chromedriver/chrome/devtools_client_impl.h"
+#include <utility>
+
#include "base/bind.h"
#include "base/json/json_reader.h"
#include "base/json/json_writer.h"
@@ -81,11 +83,10 @@ InspectorCommandResponse::~InspectorCommandResponse() {}
const char DevToolsClientImpl::kBrowserwideDevToolsClientId[] = "browser";
-DevToolsClientImpl::DevToolsClientImpl(
- const SyncWebSocketFactory& factory,
- const std::string& url,
- const std::string& id)
- : socket_(factory.Run().Pass()),
+DevToolsClientImpl::DevToolsClientImpl(const SyncWebSocketFactory& factory,
+ const std::string& url,
+ const std::string& id)
+ : socket_(factory.Run()),
url_(url),
crashed_(false),
id_(id),
@@ -100,7 +101,7 @@ DevToolsClientImpl::DevToolsClientImpl(
const std::string& url,
const std::string& id,
const FrontendCloserFunc& frontend_closer_func)
- : socket_(factory.Run().Pass()),
+ : socket_(factory.Run()),
url_(url),
crashed_(false),
id_(id),
@@ -116,7 +117,7 @@ DevToolsClientImpl::DevToolsClientImpl(
const std::string& id,
const FrontendCloserFunc& frontend_closer_func,
const ParserFunc& parser_func)
- : socket_(factory.Run().Pass()),
+ : socket_(factory.Run()),
url_(url),
crashed_(false),
id_(id),
@@ -276,7 +277,7 @@ Status DevToolsClientImpl::SendCommandInternal(
internal::InspectorCommandResponse& response = response_info->response;
if (!response.result)
return ParseInspectorError(response.error);
- *result = response.result.Pass();
+ *result = std::move(response.result);
}
return Status(kOk);
}

Powered by Google App Engine
This is Rietveld 408576698