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

Unified Diff: mojo/public/cpp/bindings/lib/map_serialization.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
« no previous file with comments | « mojo/public/cpp/bindings/lib/map_internal.h ('k') | mojo/public/cpp/bindings/lib/multiplex_router.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/cpp/bindings/lib/map_serialization.h
diff --git a/mojo/public/cpp/bindings/lib/map_serialization.h b/mojo/public/cpp/bindings/lib/map_serialization.h
index d65e7611b498ab6577b41d834d59356f30ffafb0..054cd5daa93825d85a15c32c9ccdde7f15685025 100644
--- a/mojo/public/cpp/bindings/lib/map_serialization.h
+++ b/mojo/public/cpp/bindings/lib/map_serialization.h
@@ -6,6 +6,7 @@
#define MOJO_PUBLIC_CPP_BINDINGS_LIB_MAP_SERIALIZATION_H_
#include <stddef.h>
+#include <utility>
#include "mojo/public/cpp/bindings/lib/array_internal.h"
#include "mojo/public/cpp/bindings/lib/map_data_internal.h"
@@ -150,8 +151,9 @@ inline void SerializeMap_(
input.DecomposeMapTo(&keys, &values);
const internal::ArrayValidateParams* key_validate_params =
internal::MapKeyValidateParamsFactory<DataKey>::Get();
- SerializeArray_(keys.Pass(), buf, &result->keys.ptr, key_validate_params);
- SerializeArray_(values.Pass(), buf, &result->values.ptr,
+ SerializeArray_(std::move(keys), buf, &result->keys.ptr,
+ key_validate_params);
+ SerializeArray_(std::move(values), buf, &result->values.ptr,
value_validate_params);
}
*output = result;
@@ -180,7 +182,7 @@ inline bool Deserialize_(internal::Map_Data<DataKey, DataValue>* input,
if (!Deserialize_(input->values.ptr, &values, context))
success = false;
- *output = Map<MapKey, MapValue>(keys.Pass(), values.Pass());
+ *output = Map<MapKey, MapValue>(std::move(keys), std::move(values));
} else {
output->reset();
}
« no previous file with comments | « mojo/public/cpp/bindings/lib/map_internal.h ('k') | mojo/public/cpp/bindings/lib/multiplex_router.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698