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

Unified Diff: content/browser/devtools/protocol/devtools_protocol_handler_generator.py

Issue 1549363002: Convert Pass()→std::move() in generated devtools protocol handler. (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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/devtools/protocol/devtools_protocol_handler_generator.py
diff --git a/content/browser/devtools/protocol/devtools_protocol_handler_generator.py b/content/browser/devtools/protocol/devtools_protocol_handler_generator.py
index 6377be6fdec6bdd7f2304e3daaa2a817da4f86ee..df56ffe8a5c90fc10b00ad0bde24fb54bfd73c37 100755
--- a/content/browser/devtools/protocol/devtools_protocol_handler_generator.py
+++ b/content/browser/devtools/protocol/devtools_protocol_handler_generator.py
@@ -29,6 +29,8 @@ template_h = string.Template(header + """\
#ifndef CONTENT_BROWSER_DEVTOOLS_PROTOCOL_DEVTOOLS_PROTOCOL_DISPATCHER_H_
#define CONTENT_BROWSER_DEVTOOLS_PROTOCOL_DEVTOOLS_PROTOCOL_DISPATCHER_H_
+#include <utility>
+
#include "content/browser/devtools/protocol/devtools_protocol_client.h"
namespace content {
@@ -334,7 +336,7 @@ ${prep}\
return false;
scoped_ptr<base::DictionaryValue> result(new base::DictionaryValue());
${wrap}\
- client_.SendSuccess(command_id, result.Pass());
+ client_.SendSuccess(command_id, std::move(result));
return true;
}
""")
@@ -421,7 +423,7 @@ tmpl_event_impl = string.Template("""\
void Client::${Command}(
scoped_refptr<${Command}Params> params) {
SendNotification("${Domain}.${command}",
- params->ToValue().Pass());
+ params->ToValue());
Avi (use Gerrit) 2015/12/28 15:00:22 wrap back to previous line?
}
""")
@@ -429,7 +431,7 @@ tmpl_response_impl = string.Template("""\
void Client::Send${Command}Response(
DevToolsCommandId command_id,
scoped_refptr<${Command}Response> params) {
- SendSuccess(command_id, params->ToValue().Pass());
+ SendSuccess(command_id, params->ToValue());
}
""")
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698