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

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

Issue 1855853004: Removed TODO as non-matching host rules are skipped earlier. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Corrected ASSERT for pseudo elements Created 4 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/RuleSet.cpp
diff --git a/third_party/WebKit/Source/core/css/RuleSet.cpp b/third_party/WebKit/Source/core/css/RuleSet.cpp
index e13b6e268a2a1d154b34867f1e8563be36574a48..3d19f18fafa137f28649470fec0ba735d8a81502 100644
--- a/third_party/WebKit/Source/core/css/RuleSet.cpp
+++ b/third_party/WebKit/Source/core/css/RuleSet.cpp
@@ -204,10 +204,8 @@ bool RuleSet::findBestRuleSetAndAdd(const CSSSelector& component, RuleData& rule
return true;
}
- // TODO(esprehn): We shouldn't favor tagName over m_shadowHostRules, it means
- // selectors with div:host end up in the tagName list matched against all tags
- // even though they can't match anything at all.
if (component.isHostPseudoClass()) {
+ ASSERT(component.isLastInTagHistory() || (component.relation() == CSSSelector::SubSelector && component.tagHistory()->match() == CSSSelector::PseudoElement));
m_shadowHostRules.append(ruleData);
return true;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698