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

Unified Diff: third_party/WebKit/Source/core/css/SelectorFilter.cpp

Issue 2566403003: Migrate WTF::Vector::append() to ::push_back() [part 3 of N] (Closed)
Patch Set: Created 4 years 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/core/css/SelectorFilter.cpp
diff --git a/third_party/WebKit/Source/core/css/SelectorFilter.cpp b/third_party/WebKit/Source/core/css/SelectorFilter.cpp
index 67b32b1ab493b1173059cbeeae1d6ad722d8d131..fd5b2d01774d3c958a4087ab69a34a6859d0987f 100644
--- a/third_party/WebKit/Source/core/css/SelectorFilter.cpp
+++ b/third_party/WebKit/Source/core/css/SelectorFilter.cpp
@@ -43,11 +43,11 @@ enum { TagNameSalt = 13, IdAttributeSalt = 17, ClassAttributeSalt = 19 };
static inline void collectElementIdentifierHashes(
const Element& element,
Vector<unsigned, 4>& identifierHashes) {
- identifierHashes.append(
+ identifierHashes.push_back(
element.localNameForSelectorMatching().impl()->existingHash() *
TagNameSalt);
if (element.hasID())
- identifierHashes.append(
+ identifierHashes.push_back(
element.idForStyleResolution().impl()->existingHash() *
IdAttributeSalt);
if (element.isStyledElement() && element.hasClass()) {
@@ -57,8 +57,8 @@ static inline void collectElementIdentifierHashes(
DCHECK(classNames[i].impl());
// Speculative fix for https://crbug.com/646026
if (classNames[i].impl())
- identifierHashes.append(classNames[i].impl()->existingHash() *
- ClassAttributeSalt);
+ identifierHashes.push_back(classNames[i].impl()->existingHash() *
+ ClassAttributeSalt);
}
}
}
@@ -68,7 +68,7 @@ void SelectorFilter::pushParentStackFrame(Element& parent) {
ASSERT(m_parentStack.isEmpty() ||
m_parentStack.back().element == parent.parentOrShadowHostElement());
ASSERT(!m_parentStack.isEmpty() || !parent.parentOrShadowHostElement());
- m_parentStack.append(ParentStackFrame(parent));
+ m_parentStack.push_back(ParentStackFrame(parent));
ParentStackFrame& parentFrame = m_parentStack.back();
// Mix tags, class names and ids into some sort of weird bouillabaisse.
// The filter is used for fast rejection of child and descendant selectors.
« no previous file with comments | « third_party/WebKit/Source/core/css/RuleSet.cpp ('k') | third_party/WebKit/Source/core/css/StylePropertySet.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698