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

Issue 1602833002: No pseudo elements in SelectorChecker::Mode QueryingRules. (Closed)

Created:
4 years, 11 months ago by rune
Modified:
4 years, 10 months ago
Reviewers:
esprehn
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, blink-reviews-dom_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, rwlbuis, sof
Base URL:
https://chromium.googlesource.com/chromium/src.git@remove-pseudoelm-check-2-20160118
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

No pseudo elements in SelectorChecker::Mode QueryingRules. QueryingRules mode is used by the Selectors APIs and when selecting distributed nodes from the select attribute of the <content> element in Shadow DOM V0. CSSSelector::isCompound called from HTMLContentElement::validateSelect makes sure we don't pass selectors with pseudo element selectors to the rule collector. Here we introduce a check which skips adding a selector to the selector list in SelectorDataList if it will match a pseudo element. Such selectors are still valid, and won't throw, but will result in an empty result. If no selectors are added to SelectorDataList, we just skip the DOM traversal. This means we can replace the QueryingRules check in checkPseudoElement with an assert. BUG=489481 Committed: https://crrev.com/58d20bd734ac3b61c4548fd3c9d451a9d458f3bc Cr-Commit-Position: refs/heads/master@{#372342}

Patch Set 1 #

Patch Set 2 : Rebased #

Patch Set 3 : CORE_EXPORT for unit test in component build #

Total comments: 3

Patch Set 4 : Rebased #

Patch Set 5 : Reverted ++index change and wrote regression test for it #

Patch Set 6 : Rebase fix #

Total comments: 2

Patch Set 7 : Another review issue #

Messages

Total messages: 31 (12 generated)
rune
4 years, 11 months ago (2016-01-19 00:04:54 UTC) #1
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1602833002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1602833002/1
4 years, 11 months ago (2016-01-20 13:41:35 UTC) #3
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_compile_dbg_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_compile_dbg_ng/builds/145278) linux_chromium_compile_dbg_32_ng on ...
4 years, 11 months ago (2016-01-20 14:03:30 UTC) #5
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1602833002/20002 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1602833002/20002
4 years, 11 months ago (2016-01-22 13:14:19 UTC) #7
rune
4 years, 11 months ago (2016-01-22 13:49:27 UTC) #9
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 11 months ago (2016-01-22 14:29:41 UTC) #11
rune
ptal
4 years, 11 months ago (2016-01-26 10:37:24 UTC) #12
rune
ping
4 years, 10 months ago (2016-01-29 00:52:02 UTC) #13
esprehn
https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp File third_party/WebKit/Source/core/dom/SelectorQuery.cpp (right): https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp#newcode114 third_party/WebKit/Source/core/dom/SelectorQuery.cpp:114: continue; why is it safe not to increment index ...
4 years, 10 months ago (2016-01-29 02:42:17 UTC) #14
rune
https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp File third_party/WebKit/Source/core/dom/SelectorQuery.cpp (right): https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp#newcode114 third_party/WebKit/Source/core/dom/SelectorQuery.cpp:114: continue; On 2016/01/29 02:42:17, esprehn wrote: > why is ...
4 years, 10 months ago (2016-01-29 09:53:20 UTC) #15
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1602833002/70001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1602833002/70001
4 years, 10 months ago (2016-01-29 10:57:47 UTC) #17
rune
https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp File third_party/WebKit/Source/core/dom/SelectorQuery.cpp (right): https://codereview.chromium.org/1602833002/diff/20002/third_party/WebKit/Source/core/dom/SelectorQuery.cpp#newcode114 third_party/WebKit/Source/core/dom/SelectorQuery.cpp:114: continue; On 2016/01/29 09:53:20, rune wrote: > On 2016/01/29 ...
4 years, 10 months ago (2016-01-29 10:58:44 UTC) #18
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: mac_chromium_gn_rel on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_gn_rel/builds/59224)
4 years, 10 months ago (2016-01-29 11:16:05 UTC) #20
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1602833002/90001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1602833002/90001
4 years, 10 months ago (2016-01-29 12:09:48 UTC) #22
esprehn
lgtm https://codereview.chromium.org/1602833002/diff/90001/third_party/WebKit/Source/core/dom/SelectorQuery.cpp File third_party/WebKit/Source/core/dom/SelectorQuery.cpp (right): https://codereview.chromium.org/1602833002/diff/90001/third_party/WebKit/Source/core/dom/SelectorQuery.cpp#newcode459 third_party/WebKit/Source/core/dom/SelectorQuery.cpp:459: if (!m_selectors.size()) isEmpty() ?
4 years, 10 months ago (2016-01-29 12:29:56 UTC) #23
rune
https://codereview.chromium.org/1602833002/diff/90001/third_party/WebKit/Source/core/dom/SelectorQuery.cpp File third_party/WebKit/Source/core/dom/SelectorQuery.cpp (right): https://codereview.chromium.org/1602833002/diff/90001/third_party/WebKit/Source/core/dom/SelectorQuery.cpp#newcode459 third_party/WebKit/Source/core/dom/SelectorQuery.cpp:459: if (!m_selectors.size()) On 2016/01/29 12:29:56, esprehn wrote: > isEmpty() ...
4 years, 10 months ago (2016-01-29 12:43:13 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1602833002/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1602833002/110001
4 years, 10 months ago (2016-01-29 12:43:39 UTC) #28
commit-bot: I haz the power
Committed patchset #7 (id:110001)
4 years, 10 months ago (2016-01-29 14:16:18 UTC) #29
commit-bot: I haz the power
4 years, 10 months ago (2016-01-29 14:17:16 UTC) #31
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/58d20bd734ac3b61c4548fd3c9d451a9d458f3bc
Cr-Commit-Position: refs/heads/master@{#372342}

Powered by Google App Engine
This is Rietveld 408576698