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

Unified Diff: mojo/public/cpp/bindings/map.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/router.cc ('k') | mojo/public/cpp/bindings/strong_binding.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/cpp/bindings/map.h
diff --git a/mojo/public/cpp/bindings/map.h b/mojo/public/cpp/bindings/map.h
index ef3efd3264eab1e9923698fa4fb02d229553a72e..d27eea5200364988f6dd4f02874ddad770386f2f 100644
--- a/mojo/public/cpp/bindings/map.h
+++ b/mojo/public/cpp/bindings/map.h
@@ -6,8 +6,8 @@
#define MOJO_PUBLIC_CPP_BINDINGS_MAP_H_
#include <stddef.h>
-
#include <map>
+#include <utility>
#include "mojo/public/cpp/bindings/lib/map_internal.h"
#include "mojo/public/cpp/bindings/lib/value_traits.h"
@@ -55,7 +55,7 @@ class Map {
// corresponding |values|.
Map(mojo::Array<Key> keys, mojo::Array<Value> values) : is_null_(false) {
MOJO_DCHECK(keys.size() == values.size());
- Traits::InitializeFrom(&map_, keys.Pass(), values.Pass());
+ Traits::InitializeFrom(&map_, std::move(keys), std::move(values));
}
~Map() { Traits::Finalize(&map_); }
@@ -158,7 +158,7 @@ class Map {
Map result;
result.is_null_ = is_null_;
Traits::Clone(map_, &result.map_);
- return result.Pass();
+ return std::move(result);
}
// Indicates whether the contents of this map are equal to those of another
@@ -268,7 +268,7 @@ struct TypeConverter<Map<MojoKey, MojoValue>, std::map<STLKey, STLValue>> {
result.insert(TypeConverter<MojoKey, STLKey>::Convert(pair.first),
TypeConverter<MojoValue, STLValue>::Convert(pair.second));
}
- return result.Pass();
+ return std::move(result);
}
};
« no previous file with comments | « mojo/public/cpp/bindings/lib/router.cc ('k') | mojo/public/cpp/bindings/strong_binding.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698