New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
style: More traversal cleanup. #19164
Conversation
Heads up! This PR modifies the following files:
|
r? @bzbarsky |
79afd0a
to
6732759
Compare
6732759
to
cd51bcb
Compare
@bors-servo try (Also, @nox or @SimonSapin may want to stamp it if they feel confident about it) |
style: More traversal cleanup. This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19164) <!-- Reviewable:end -->
💔 Test failed - linux-rel-wpt |
@bors-servo try |
style: More traversal cleanup. This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19164) <!-- Reviewable:end -->
💔 Test failed - mac-rel-css2 |
7714390
to
17e0ec4
Compare
@bors-servo try This should be ready for review, I had to fix a Servo bug (39f6bb7). |
style: More traversal cleanup. This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19164) <!-- Reviewable:end -->
💔 Test failed - mac-rel-wpt4 |
…pposed from add_child / remove_child. add_child / remove_child aren't called when a node character data changed. The only test that tests this is now wallpapered, but won't be after servo#19164. Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
…ad of add_child / remove_child. add_child / remove_child aren't called when a node character data changed. This is important for finer grained invalidation. The only test that tests this is now wallpapered, but won't be after servo#19164.
17e0ec4
to
9d8e92a
Compare
@bors-servo try |
style: More traversal cleanup. This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19164) <!-- Reviewable:end -->
☀️ Test successful - android, arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css1, mac-rel-css2, mac-rel-wpt1, mac-rel-wpt2, mac-rel-wpt3, mac-rel-wpt4, windows-msvc-dev |
components/script/dom/node.rs
Outdated
// rooting? I'm pretty sure this cannot GC! | ||
let mut current = Some(DomRoot::from_ref(self)); | ||
|
||
while let Some(node) = current.take() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's no good answer for the rooting question, unfortunately. As for this code, let's use:
for node in self.ancestors() {
if node.get_flag(...) {
return;
}
node.set_flag(...);
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed it to inclusive_ancestors, which is what it is intended to do.
…ramed. We only need to do this when display changes from none to non-none, so handle it explicitly when computing the cascade requirement. This patch also removes a few conditions that are redundant because they're handled also by the cascade requirement check, like the initial styling.
9d8e92a
to
3a5d70f
Compare
@bors-servo r+ |
📌 Commit 3a5d70f has been approved by |
@bors-servo p=1 |
style: More traversal cleanup. This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19164) <!-- Reviewable:end -->
☀️ Test successful - android, arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css1, mac-rel-css2, mac-rel-wpt1, mac-rel-wpt2, mac-rel-wpt3, mac-rel-wpt4, windows-msvc-dev |
This is cleanup that allows me to fix https://bugzilla.mozilla.org/show_bug.cgi?id=1415013 in a more straight-forward way.
This change is