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

Unified Diff: mojo/services/tracing/public/cpp/trace_provider_impl.cc

Issue 1539863002: Convert Pass()→std::move() in mojo/services/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix missing forward declare that was masked by pre-existing incorrect #include ordering. 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/services/test_service/tracked_service.cc ('k') | mojo/services/tracing/public/cpp/tracing_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/services/tracing/public/cpp/trace_provider_impl.cc
diff --git a/mojo/services/tracing/public/cpp/trace_provider_impl.cc b/mojo/services/tracing/public/cpp/trace_provider_impl.cc
index 785d20f11153974bbdfbb437f9ae757fc1963e4a..e9190f59e3fcec45aff5262f64605b4371115869 100644
--- a/mojo/services/tracing/public/cpp/trace_provider_impl.cc
+++ b/mojo/services/tracing/public/cpp/trace_provider_impl.cc
@@ -4,6 +4,8 @@
#include "mojo/services/tracing/public/cpp/trace_provider_impl.h"
+#include <utility>
+
#include "base/callback.h"
#include "base/logging.h"
#include "base/memory/weak_ptr.h"
@@ -22,7 +24,7 @@ TraceProviderImpl::~TraceProviderImpl() {}
void TraceProviderImpl::Bind(InterfaceRequest<tracing::TraceProvider> request) {
if (!binding_.is_bound()) {
- binding_.Bind(request.Pass());
+ binding_.Bind(std::move(request));
} else {
LOG(ERROR) << "Cannot accept two connections to TraceProvider.";
}
@@ -31,7 +33,7 @@ void TraceProviderImpl::Bind(InterfaceRequest<tracing::TraceProvider> request) {
void TraceProviderImpl::StartTracing(const String& categories,
tracing::TraceRecorderPtr recorder) {
DCHECK(!recorder_);
- recorder_ = recorder.Pass();
+ recorder_ = std::move(recorder);
tracing_forced_ = false;
if (!base::trace_event::TraceLog::GetInstance()->IsEnabled()) {
std::string categories_str = categories.To<std::string>();
« no previous file with comments | « mojo/services/test_service/tracked_service.cc ('k') | mojo/services/tracing/public/cpp/tracing_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698