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

Unified Diff: base/profiler/stack_sampling_profiler.h

Issue 1852433005: Convert //base to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase after r384946 Created 4 years, 8 months 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 | « base/profiler/native_stack_sampler_win.cc ('k') | base/profiler/stack_sampling_profiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/profiler/stack_sampling_profiler.h
diff --git a/base/profiler/stack_sampling_profiler.h b/base/profiler/stack_sampling_profiler.h
index e972d57c23701ef25ca83144bb26c0befa1dce39..9424ca0081b78d9b4681b7d08ac7521dd71b106b 100644
--- a/base/profiler/stack_sampling_profiler.h
+++ b/base/profiler/stack_sampling_profiler.h
@@ -7,6 +7,7 @@
#include <stddef.h>
+#include <memory>
#include <string>
#include <vector>
@@ -14,7 +15,6 @@
#include "base/callback.h"
#include "base/files/file_path.h"
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "base/strings/string16.h"
#include "base/synchronization/waitable_event.h"
#include "base/threading/platform_thread.h"
@@ -197,7 +197,7 @@ class BASE_EXPORT StackSamplingProfiler {
// Samples stacks using |native_sampler|. When complete, invokes
// |completed_callback| with the collected call stack profiles.
// |completed_callback| must be callable on any thread.
- SamplingThread(scoped_ptr<NativeStackSampler> native_sampler,
+ SamplingThread(std::unique_ptr<NativeStackSampler> native_sampler,
const SamplingParams& params,
const CompletedCallback& completed_callback);
~SamplingThread() override;
@@ -219,7 +219,7 @@ class BASE_EXPORT StackSamplingProfiler {
// |call_stack_profiles| may contain a partial burst.
void CollectProfiles(CallStackProfiles* profiles);
- scoped_ptr<NativeStackSampler> native_sampler_;
+ std::unique_ptr<NativeStackSampler> native_sampler_;
const SamplingParams params_;
// If Stop() is called, it signals this event to force the sampling to
@@ -236,7 +236,7 @@ class BASE_EXPORT StackSamplingProfiler {
const SamplingParams params_;
- scoped_ptr<SamplingThread> sampling_thread_;
+ std::unique_ptr<SamplingThread> sampling_thread_;
PlatformThreadHandle sampling_thread_handle_;
const CompletedCallback completed_callback_;
« no previous file with comments | « base/profiler/native_stack_sampler_win.cc ('k') | base/profiler/stack_sampling_profiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698