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

Unified Diff: third_party/WebKit/Source/wtf/text/StringImpl.cpp

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 years, 6 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 | « third_party/WebKit/Source/wtf/text/Collator.h ('k') | third_party/WebKit/Source/wtf/text/TextCodec.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/wtf/text/StringImpl.cpp
diff --git a/third_party/WebKit/Source/wtf/text/StringImpl.cpp b/third_party/WebKit/Source/wtf/text/StringImpl.cpp
index c9c1a14b885bbf01ad1efb2bf7058f4da0b2f04f..77ddb659b1e7524b56b8cb465b98ade6258526b1 100644
--- a/third_party/WebKit/Source/wtf/text/StringImpl.cpp
+++ b/third_party/WebKit/Source/wtf/text/StringImpl.cpp
@@ -26,8 +26,7 @@
#include "wtf/DynamicAnnotations.h"
#include "wtf/LeakAnnotations.h"
-#include "wtf/OwnPtr.h"
-#include "wtf/PassOwnPtr.h"
+#include "wtf/PtrUtil.h"
#include "wtf/StdLibExtras.h"
#include "wtf/allocator/PartitionAlloc.h"
#include "wtf/allocator/Partitions.h"
@@ -37,6 +36,7 @@
#include "wtf/text/StringHash.h"
#include "wtf/text/StringToNumber.h"
#include <algorithm>
+#include <memory>
#include <unicode/translit.h>
#include <unicode/unistr.h>
@@ -793,8 +793,8 @@ PassRefPtr<StringImpl> StringImpl::upper(const AtomicString& localeIdentifier)
// TODO(jungshik): Cache transliterator if perf penaly warrants it for Greek.
UErrorCode status = U_ZERO_ERROR;
- OwnPtr<icu::Transliterator> translit =
- adoptPtr(icu::Transliterator::createInstance(transliteratorId, UTRANS_FORWARD, status));
+ std::unique_ptr<icu::Transliterator> translit =
+ wrapUnique(icu::Transliterator::createInstance(transliteratorId, UTRANS_FORWARD, status));
if (U_FAILURE(status))
return upper();
« no previous file with comments | « third_party/WebKit/Source/wtf/text/Collator.h ('k') | third_party/WebKit/Source/wtf/text/TextCodec.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698