Index: gin/modules/module_registry.cc |
diff --git a/gin/modules/module_registry.cc b/gin/modules/module_registry.cc |
index 10d5464f670a58048feca220c29884a0e0e78dd5..deec1874b485242828fce9b09a058ad13c543be3 100644 |
--- a/gin/modules/module_registry.cc |
+++ b/gin/modules/module_registry.cc |
@@ -6,8 +6,8 @@ |
#include <stddef.h> |
#include <stdint.h> |
- |
#include <string> |
+#include <utility> |
#include <vector> |
#include "base/logging.h" |
@@ -83,7 +83,7 @@ void Define(const v8::FunctionCallbackInfo<Value>& info) { |
ModuleRegistry* registry = |
ModuleRegistry::From(args.isolate()->GetCurrentContext()); |
- registry->AddPendingModule(args.isolate(), pending.Pass()); |
+ registry->AddPendingModule(args.isolate(), std::move(pending)); |
} |
WrapperInfo g_wrapper_info = { kEmbedderNativeGin }; |
@@ -161,7 +161,7 @@ void ModuleRegistry::AddPendingModule(Isolate* isolate, |
scoped_ptr<PendingModule> pending) { |
const std::string pending_id = pending->id; |
const std::vector<std::string> pending_dependencies = pending->dependencies; |
- AttemptToLoad(isolate, pending.Pass()); |
+ AttemptToLoad(isolate, std::move(pending)); |
FOR_EACH_OBSERVER(ModuleRegistryObserver, observer_list_, |
OnDidAddPendingModule(pending_id, pending_dependencies)); |
} |
@@ -258,7 +258,7 @@ bool ModuleRegistry::AttemptToLoad(Isolate* isolate, |
pending_modules_.push_back(pending.release()); |
return false; |
} |
- return Load(isolate, pending.Pass()); |
+ return Load(isolate, std::move(pending)); |
} |
v8::Local<v8::Value> ModuleRegistry::GetModule(v8::Isolate* isolate, |
@@ -278,7 +278,7 @@ void ModuleRegistry::AttemptToLoadMoreModules(Isolate* isolate) { |
for (size_t i = 0; i < pending_modules.size(); ++i) { |
scoped_ptr<PendingModule> pending(pending_modules[i]); |
pending_modules[i] = NULL; |
- if (AttemptToLoad(isolate, pending.Pass())) |
+ if (AttemptToLoad(isolate, std::move(pending))) |
keep_trying = true; |
} |
} |