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

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

Issue 2741023002: Migrate WTF::Deque::removeLast() to ::pop_back() (Closed)
Patch Set: 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 b6b69b2d351103c04a06b3d671cdaeb44dce5699..eb338fb63226497dc2e4cee17318a4f0230bb9c3 100644
--- a/third_party/WebKit/Source/wtf/Deque.h
+++ b/third_party/WebKit/Source/wtf/Deque.h
@@ -130,7 +130,6 @@ class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>,
template <typename U>
void prepend(U&&);
void removeFirst();
- void removeLast();
void remove(iterator&);
void remove(const_iterator&);
@@ -143,7 +142,7 @@ class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>,
void push_front(U&& u) {
prepend(std::forward<U>(u));
}
- void pop_back() { removeLast(); }
+ void pop_back();
void pop_front() { removeFirst(); }
bool empty() const { return isEmpty(); }
T& front() { return first(); }
@@ -498,7 +497,7 @@ inline T Deque<T, inlineCapacity, Allocator>::takeFirst() {
template <typename T, size_t inlineCapacity, typename Allocator>
inline T Deque<T, inlineCapacity, Allocator>::takeLast() {
T oldLast = std::move(last());
- removeLast();
+ pop_back();
return oldLast;
}
@@ -562,7 +561,7 @@ inline void Deque<T, inlineCapacity, Allocator>::removeFirst() {
}
template <typename T, size_t inlineCapacity, typename Allocator>
-inline void Deque<T, inlineCapacity, Allocator>::removeLast() {
+inline void Deque<T, inlineCapacity, Allocator>::pop_back() {
DCHECK(!isEmpty());
if (!m_end)
m_end = m_buffer.capacity() - 1;
« no previous file with comments | « third_party/WebKit/Source/platform/fonts/ScriptRunIterator.cpp ('k') | third_party/WebKit/Source/wtf/DequeTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698