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

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

Issue 2743023002: Migrate WTF::Deque::append() to ::push_back() (Closed)
Patch Set: rebase Created 3 years, 9 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
Index: third_party/WebKit/Source/wtf/Deque.h
diff --git a/third_party/WebKit/Source/wtf/Deque.h b/third_party/WebKit/Source/wtf/Deque.h
index eb338fb63226497dc2e4cee17318a4f0230bb9c3..7d3689a16d51d0b4c512e2af01f5b9509ff7bc4f 100644
--- a/third_party/WebKit/Source/wtf/Deque.h
+++ b/third_party/WebKit/Source/wtf/Deque.h
@@ -126,8 +126,6 @@ class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>,
const T& operator[](size_t i) const { return at(i); }
template <typename U>
- void append(U&&);
- template <typename U>
void prepend(U&&);
void removeFirst();
void remove(iterator&);
@@ -135,9 +133,7 @@ class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>,
// STL compatibility.
template <typename U>
- void push_back(U&& u) {
- append(std::forward<U>(u));
- }
+ void push_back(U&&);
template <typename U>
void push_front(U&& u) {
prepend(std::forward<U>(u));
@@ -503,7 +499,7 @@ inline T Deque<T, inlineCapacity, Allocator>::takeLast() {
template <typename T, size_t inlineCapacity, typename Allocator>
template <typename U>
-inline void Deque<T, inlineCapacity, Allocator>::append(U&& value) {
+inline void Deque<T, inlineCapacity, Allocator>::push_back(U&& value) {
expandCapacityIfNeeded();
T* newElement = &m_buffer.buffer()[m_end];
if (m_end == m_buffer.capacity() - 1)
« no previous file with comments | « third_party/WebKit/Source/platform/text/SegmentedString.cpp ('k') | third_party/WebKit/Source/wtf/DequeTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698