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

Unified Diff: third_party/WebKit/Source/core/dom/SelectorQuery.h

Issue 2774663003: Simplify the SelectorQuery constructor and reuse CSSSelectorList::length(). (Closed)
Patch Set: woops 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/core/dom/SelectorQuery.h
diff --git a/third_party/WebKit/Source/core/dom/SelectorQuery.h b/third_party/WebKit/Source/core/dom/SelectorQuery.h
index 3dbe765305c91073c0455ff50f81b27cc9a8c473..149cf5b386723a783fbf080fec4b8b15de7e0cb6 100644
--- a/third_party/WebKit/Source/core/dom/SelectorQuery.h
+++ b/third_party/WebKit/Source/core/dom/SelectorQuery.h
@@ -104,6 +104,10 @@ class CORE_EXPORT SelectorQuery {
typename SelectorQueryTrait::OutputType&) const;
CSSSelectorList m_selectorList;
+ // Contains the list of CSSSelector's to match, but without ones that could
+ // never match like pseudo elements, div::before. This can be empty, while
+ // m_selectorList will never be empty as SelectorQueryCache::add would have
+ // thrown an exception.
Vector<const CSSSelector*> m_selectors;
bool m_usesDeepCombinatorOrShadowPseudo : 1;
bool m_needsUpdatedDistribution : 1;
« no previous file with comments | « third_party/WebKit/Source/core/css/CSSSelectorList.cpp ('k') | third_party/WebKit/Source/core/dom/SelectorQuery.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698