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

Unified Diff: base/md5_unittest.cc

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/macros.h ('k') | base/memory/aligned_memory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/md5_unittest.cc
diff --git a/base/md5_unittest.cc b/base/md5_unittest.cc
index 3926b66ae3015d7ef9d60b990fa8c78fe549a119..b27efe9f96f00836cee30d45d6e532738f3d6e36 100644
--- a/base/md5_unittest.cc
+++ b/base/md5_unittest.cc
@@ -2,11 +2,13 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "base/md5.h"
+
#include <string.h>
+
+#include <memory>
#include <string>
-#include "base/memory/scoped_ptr.h"
-#include "base/md5.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace base {
@@ -66,7 +68,7 @@ TEST(MD5, MD5SumOneByteData) {
TEST(MD5, MD5SumLongData) {
const int length = 10 * 1024 * 1024 + 1;
- scoped_ptr<char[]> data(new char[length]);
+ std::unique_ptr<char[]> data(new char[length]);
for (int i = 0; i < length; ++i)
data[i] = i & 0xFF;
@@ -108,7 +110,7 @@ TEST(MD5, ContextWithLongData) {
MD5Init(&ctx);
const int length = 10 * 1024 * 1024 + 1;
- scoped_ptr<char[]> data(new char[length]);
+ std::unique_ptr<char[]> data(new char[length]);
for (int i = 0; i < length; ++i)
data[i] = i & 0xFF;
« no previous file with comments | « base/macros.h ('k') | base/memory/aligned_memory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698