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

Unified Diff: mojo/public/cpp/bindings/lib/interface_ptr_state.h

Issue 1535943002: Convert Pass()→std::move() in //mojo/public/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Regenerate correctly 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: mojo/public/cpp/bindings/lib/interface_ptr_state.h
diff --git a/mojo/public/cpp/bindings/lib/interface_ptr_state.h b/mojo/public/cpp/bindings/lib/interface_ptr_state.h
index 1ac1416886a238202b6e86b64f223cabd199bed1..0fb44f517424289666d3bbd878282a998cb4bf9e 100644
--- a/mojo/public/cpp/bindings/lib/interface_ptr_state.h
+++ b/mojo/public/cpp/bindings/lib/interface_ptr_state.h
@@ -6,8 +6,8 @@
#define MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_
#include <stdint.h>
-
#include <algorithm> // For |std::swap()|.
+#include <utility>
#include "base/logging.h"
#include "base/macros.h"
@@ -125,7 +125,7 @@ class InterfacePtrState<Interface, false> {
// shouldn't be reused.
InterfacePtrInfo<GenericInterface> PassInterface() {
return InterfacePtrInfo<GenericInterface>(
- router_ ? router_->PassMessagePipe() : handle_.Pass(), version_);
+ router_ ? router_->PassMessagePipe() : std::move(handle_), version_);
}
bool is_bound() const { return handle_.is_valid() || router_; }
@@ -172,7 +172,7 @@ class InterfacePtrState<Interface, false> {
filters.Append<MessageHeaderValidator>();
filters.Append<typename Interface::ResponseValidator_>();
- router_ = new Router(handle_.Pass(), filters.Pass(), waiter_);
+ router_ = new Router(std::move(handle_), std::move(filters), waiter_);
waiter_ = nullptr;
proxy_ = new Proxy(router_);
@@ -334,7 +334,7 @@ class InterfacePtrState<Interface, true> {
return;
}
- router_ = new MultiplexRouter(true, handle_.Pass(), waiter_);
+ router_ = new MultiplexRouter(true, std::move(handle_), waiter_);
endpoint_client_.reset(new InterfaceEndpointClient(
router_->CreateLocalEndpointHandle(kMasterInterfaceId), nullptr,
make_scoped_ptr(new typename Interface::ResponseValidator_())));
« no previous file with comments | « mojo/public/cpp/bindings/lib/interface_endpoint_client.cc ('k') | mojo/public/cpp/bindings/lib/map_internal.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698