diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2017-09-11 05:26:46 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-11 05:26:46 -0500 |
commit | 6a09b1d21abd66d6954d8107f4439c33054ee264 (patch) | |
tree | e3e9f12c84ef906b01bd86f7abc674c44daaa765 /components/script/dom/performance.rs | |
parent | 7fc2c435513feadf1dc666e7873095884dfd6d84 (diff) | |
parent | 3877e9162f1b0ff55e26707e681efe35fba62434 (diff) | |
download | servo-6a09b1d21abd66d6954d8107f4439c33054ee264.tar.gz servo-6a09b1d21abd66d6954d8107f4439c33054ee264.zip |
Auto merge of #18372 - tigercosmos:userTimingApi, r=ferjm
TEST: fix and add case of po-observe.any.js
<!-- Please describe your changes on the following line: -->
1. implementing step 3 from the [`PerformanceObserver.observe()`](https://w3c.github.io/performance-timeline/#dom-performanceobserver-observe()) method spec properly.
2. also add cases about step 1 & 2
work on the top of #18283
r? @ferjm
---
<!-- 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 #18285 (github issue number if applicable).
<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____
<!-- 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/18372)
<!-- Reviewable:end -->
Diffstat (limited to 'components/script/dom/performance.rs')
-rw-r--r-- | components/script/dom/performance.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/components/script/dom/performance.rs b/components/script/dom/performance.rs index 7cef2f28010..7d2b053dda7 100644 --- a/components/script/dom/performance.rs +++ b/components/script/dom/performance.rs @@ -163,7 +163,7 @@ impl Performance { observer.set_entries(obs_entries); } let mut observers = self.observers.borrow_mut(); - match observers.iter().position(|o| &(*o.observer) == observer) { + match observers.iter().position(|o| *o.observer == *observer) { // If the observer is already in the list, we only update the observed // entry types. Some(p) => observers[p].entry_types = entry_types, |