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

Unified Diff: cc/base/contiguous_container.cc

Issue 1866203004: Convert //cc from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptrcc: rebase 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 | « cc/base/contiguous_container.h ('k') | cc/base/list_container.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/base/contiguous_container.cc
diff --git a/cc/base/contiguous_container.cc b/cc/base/contiguous_container.cc
index b56b26baad91631d677334e9fc097ed6bffd1b99..d6280b43290b8d4d9547f56a1a62b070caf63e66 100644
--- a/cc/base/contiguous_container.cc
+++ b/cc/base/contiguous_container.cc
@@ -44,7 +44,7 @@ class ContiguousContainerBase::Buffer {
const char* begin() const { return &data_[0]; }
// begin() <= end_ <= begin() + capacity_
- scoped_ptr<char[]> data_;
+ std::unique_ptr<char[]> data_;
char* end_;
size_t capacity_;
};
@@ -136,7 +136,7 @@ ContiguousContainerBase::Buffer*
ContiguousContainerBase::AllocateNewBufferForNextAllocation(
size_t buffer_size) {
DCHECK(buffers_.empty() || end_index_ == buffers_.size() - 1);
- scoped_ptr<Buffer> new_buffer(new Buffer(buffer_size));
+ std::unique_ptr<Buffer> new_buffer(new Buffer(buffer_size));
Buffer* buffer_to_return = new_buffer.get();
buffers_.push_back(std::move(new_buffer));
end_index_ = buffers_.size() - 1;
« no previous file with comments | « cc/base/contiguous_container.h ('k') | cc/base/list_container.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698