aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkRefCnt.h
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2016-03-10 10:10:03 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-03-10 10:10:03 -0800
commit20c1e3abfc681771f73eb19fde7284196e028940 (patch)
tree68ce99423776fbf759f2574138c69eafc675ac69 /include/core/SkRefCnt.h
parent8e478812815f7494c45afb8cf6f077f548b55daa (diff)
Use std::unique_ptr.
TBR=reed@google.com Review URL: https://codereview.chromium.org/1780933003
Diffstat (limited to 'include/core/SkRefCnt.h')
-rw-r--r--include/core/SkRefCnt.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/core/SkRefCnt.h b/include/core/SkRefCnt.h
index f159e3b1b7..5e334395a9 100644
--- a/include/core/SkRefCnt.h
+++ b/include/core/SkRefCnt.h
@@ -9,9 +9,10 @@
#define SkRefCnt_DEFINED
#include "../private/SkAtomics.h"
-#include "../private/SkUniquePtr.h"
+#include "../private/SkTLogic.h"
#include "SkTypes.h"
#include <functional>
+#include <memory>
#include <utility>
#define SK_SUPPORT_TRANSITION_TO_SP_INTERFACES
@@ -189,9 +190,9 @@ template <typename T> struct SkTUnref {
/**
* Utility class that simply unref's its argument in the destructor.
*/
-template <typename T> class SkAutoTUnref : public skstd::unique_ptr<T, SkTUnref<T>> {
+template <typename T> class SkAutoTUnref : public std::unique_ptr<T, SkTUnref<T>> {
public:
- explicit SkAutoTUnref(T* obj = nullptr) : skstd::unique_ptr<T, SkTUnref<T>>(obj) {}
+ explicit SkAutoTUnref(T* obj = nullptr) : std::unique_ptr<T, SkTUnref<T>>(obj) {}
T* detach() { return this->release(); }
operator T*() const { return this->get(); }