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

Unified Diff: third_party/mojo/src/mojo/edk/system/message_in_transit.cc

Issue 1545333002: Convert Pass()→std::move() in //third_party/mojo (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: third_party/mojo/src/mojo/edk/system/message_in_transit.cc
diff --git a/third_party/mojo/src/mojo/edk/system/message_in_transit.cc b/third_party/mojo/src/mojo/edk/system/message_in_transit.cc
index a40981d0cc6c8b373fcbf3237b3466085b5163e9..000b993d84ef79e0c08195c540980b11de0ba7b7 100644
--- a/third_party/mojo/src/mojo/edk/system/message_in_transit.cc
+++ b/third_party/mojo/src/mojo/edk/system/message_in_transit.cc
@@ -5,8 +5,8 @@
#include "third_party/mojo/src/mojo/edk/system/message_in_transit.h"
#include <string.h>
-
#include <ostream>
+#include <utility>
#include "base/logging.h"
#include "third_party/mojo/src/mojo/edk/system/configuration.h"
@@ -149,7 +149,7 @@ void MessageInTransit::SetDispatchers(
DCHECK(!dispatchers_);
DCHECK(!transport_data_);
- dispatchers_ = dispatchers.Pass();
+ dispatchers_ = std::move(dispatchers);
#ifndef NDEBUG
for (size_t i = 0; i < dispatchers_->size(); i++)
DCHECK(!(*dispatchers_)[i] || (*dispatchers_)[i]->HasOneRef());
@@ -162,7 +162,7 @@ void MessageInTransit::SetTransportData(
DCHECK(!transport_data_);
DCHECK(!dispatchers_);
- transport_data_ = transport_data.Pass();
+ transport_data_ = std::move(transport_data);
UpdateTotalSize();
}
@@ -173,7 +173,7 @@ void MessageInTransit::SerializeAndCloseDispatchers(Channel* channel) {
if (!dispatchers_ || !dispatchers_->size())
return;
- transport_data_.reset(new TransportData(dispatchers_.Pass(), channel));
+ transport_data_.reset(new TransportData(std::move(dispatchers_), channel));
// Update the sizes in the message header.
UpdateTotalSize();

Powered by Google App Engine
This is Rietveld 408576698