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

Unified Diff: third_party/WebKit/Source/wtf/Vector.h

Issue 1425533005: Rename DefaultAllocator to PartitionAllocator (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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/Partitions.cpp ('k') | third_party/WebKit/Source/wtf/wtf.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/wtf/Vector.h
diff --git a/third_party/WebKit/Source/wtf/Vector.h b/third_party/WebKit/Source/wtf/Vector.h
index 1d9da908a3df129804bd1ee6911ab120105b6246..6f6ced3ee12989222cea0c40c9548ced6f748247 100644
--- a/third_party/WebKit/Source/wtf/Vector.h
+++ b/third_party/WebKit/Source/wtf/Vector.h
@@ -24,9 +24,9 @@
#include "wtf/Alignment.h"
#include "wtf/ConditionalDestructor.h"
#include "wtf/ContainerAnnotations.h"
-#include "wtf/DefaultAllocator.h"
#include "wtf/Noncopyable.h"
#include "wtf/NotFound.h"
+#include "wtf/PartitionAllocator.h"
#include "wtf/StdLibExtras.h"
#include "wtf/VectorTraits.h"
#include <algorithm>
@@ -366,7 +366,7 @@ protected:
unsigned m_size;
};
-template <typename T, size_t inlineCapacity, typename Allocator = DefaultAllocator>
+template <typename T, size_t inlineCapacity, typename Allocator = PartitionAllocator>
class VectorBuffer;
template <typename T, typename Allocator>
@@ -614,7 +614,7 @@ private:
friend class Deque;
};
-template <typename T, size_t inlineCapacity = 0, typename Allocator = DefaultAllocator> // Heap-allocated vectors with no inlineCapacity never need a destructor.
+template <typename T, size_t inlineCapacity = 0, typename Allocator = PartitionAllocator> // Heap-allocated vectors with no inlineCapacity never need a destructor.
class Vector : private VectorBuffer<T, INLINE_CAPACITY, Allocator>, public ConditionalDestructor<Vector<T, INLINE_CAPACITY, Allocator>, (INLINE_CAPACITY == 0) && Allocator::isGarbageCollected> {
WTF_USE_ALLOCATOR(Vector, Allocator);
typedef VectorBuffer<T, INLINE_CAPACITY, Allocator> Base;
@@ -1046,7 +1046,7 @@ void Vector<T, inlineCapacity, Allocator>::reserveCapacity(size_t newCapacity)
#endif
// The Allocator::isGarbageCollected check is not needed. The check is just
// a static hint for a compiler to indicate that Base::expandBuffer returns
- // false if Allocator is a DefaultAllocator.
+ // false if Allocator is a PartitionAllocator.
if (Allocator::isGarbageCollected && Base::expandBuffer(newCapacity)) {
ANNOTATE_CHANGE_CAPACITY(begin(), oldCapacity, m_size, capacity());
return;
« no previous file with comments | « third_party/WebKit/Source/wtf/Partitions.cpp ('k') | third_party/WebKit/Source/wtf/wtf.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698