Skip to content
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

Split getter for mutation_observers() into two methods. #23529

Merged
merged 1 commit into from Jun 10, 2019

Conversation

@gatoWololo
Copy link
Contributor

gatoWololo commented Jun 6, 2019

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes fix #23286
  • These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/changes.

This change is Reviewable

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.
@highfive
Copy link

highfive commented Jun 6, 2019

Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @jdm (or someone else) soon.

@highfive
Copy link

highfive commented Jun 6, 2019

Heads up! This PR modifies the following files:

  • @asajeffrey: components/script/dom/node.rs, components/script/dom/mutationobserver.rs
  • @KiChjang: components/script/dom/node.rs, components/script/dom/mutationobserver.rs
@highfive
Copy link

highfive commented Jun 6, 2019

warning Warning warning

  • These commits modify script code, but no tests are modified. Please consider adding a test!
@jdm
Copy link
Member

jdm commented Jun 6, 2019

r? @ferjm

@highfive highfive assigned ferjm and unassigned jdm Jun 6, 2019
@ferjm
Copy link
Member

ferjm commented Jun 10, 2019

Thanks!
@bors-servo r+

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

📌 Commit 3df8d68 has been approved by ferjm

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

Testing commit 3df8d68 with merge fd6e881...

bors-servo added a commit that referenced this pull request Jun 10, 2019
Split getter for mutation_observers() into two methods.

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23286

<!-- Either: -->
- [X] These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/changes.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23529)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💔 Test failed - status-taskcluster

@ferjm
Copy link
Member

ferjm commented Jun 10, 2019

@bors-servo retry

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💣 Failed to start rebuilding: Unknown error

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

Testing commit 3df8d68 with merge ecb62c4...

bors-servo added a commit that referenced this pull request Jun 10, 2019
Split getter for mutation_observers() into two methods.

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23286

<!-- Either: -->
- [X] These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/changes.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23529)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💔 Test failed - status-taskcluster

@jdm
Copy link
Member

jdm commented Jun 10, 2019

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💣 Failed to start rebuilding: Unknown error

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

Testing commit 3df8d68 with merge 9c4f03f...

bors-servo added a commit that referenced this pull request Jun 10, 2019
Split getter for mutation_observers() into two methods.

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23286

<!-- Either: -->
- [X] These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/changes.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23529)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💔 Test failed - status-taskcluster

@jdm
Copy link
Member

jdm commented Jun 10, 2019

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💣 Failed to start rebuilding: Unknown error

2 similar comments
@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💣 Failed to start rebuilding: Unknown error

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

💣 Failed to start rebuilding: Unknown error

@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

Testing commit 3df8d68 with merge 4c776f3...

bors-servo added a commit that referenced this pull request Jun 10, 2019
Split getter for mutation_observers() into two methods.

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23286

<!-- Either: -->
- [X] These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/changes.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23529)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jun 10, 2019

☀️ Test successful - arm64, linux-rel-css, linux-rel-wpt, status-taskcluster
Approved by: ferjm
Pushing 4c776f3 to master...

@bors-servo bors-servo merged commit 3df8d68 into servo:master Jun 10, 2019
4 checks passed
4 checks passed
Taskcluster (pull_request) TaskGroup: success
Details
Travis CI - Pull Request Build Passed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

6 participants
You can’t perform that action at this time.