Provide the fetched data to fetch() consumers.#13597
Merged
bors-servo merged 2 commits intomasterfrom Oct 6, 2016
Merged
Conversation
|
Heads up! This PR modifies the following files:
|
Contributor
Author
|
@bors-servo try |
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 5, 2016
Provide the fetched data to fetch() consumers.
jdm
requested changes
Oct 5, 2016
components/script/dom/request.rs
Outdated
|
|
||
| fn set_body_promise(&self, p: &Rc<Promise>, body_type: BodyType) { | ||
| self.body_used.set(true); | ||
| assert!(mem::replace(&mut *self.body_promise.borrow_mut(), Some((p.clone(), body_type))).is_none()); |
components/script/dom/response.rs
Outdated
|
|
||
| fn set_body_promise(&self, p: &Rc<Promise>, body_type: BodyType) { | ||
| self.body_used.set(true); | ||
| assert!(mem::replace(&mut *self.body_promise.borrow_mut(), Some((p.clone(), body_type))).is_none()); |
Member
There was a problem hiding this comment.
This is a complicated way of writing
assert!(self.body_promise.borrow().is_none());
*self.body_promise.borrow_mut() = Some(p.clone(), body_type);which I would prefer.
| } | ||
|
|
||
| // https://fetch.spec.whatwg.org/#concept-body-consume-body | ||
| #[allow(unrooted_must_root)] |
components/script/body.rs
Outdated
| }; | ||
| }, | ||
| Err(err) => promise.reject_error(cx, err), | ||
| if let Some(body) = object.take_body() { |
Member
There was a problem hiding this comment.
let body = match object.take_body() {
Some(body) => body,
None => return,
};
Contributor
|
💔 Test failed - mac-rel-wpt1 |
Contributor
Author
|
@bors-servo try |
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 5, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
💔 Test failed - linux-rel-wpt |
Member
|
We probably need a compartment for the JSON case. |
Contributor
Author
|
@bors-servo try |
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 6, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
💔 Test failed - mac-rel-wpt1 |
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 6, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
💔 Test failed - mac-rel-css |
Contributor
Author
|
@bors-servo retry |
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 6, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
@bors-servo clean force retry
|
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 6, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
💔 Test failed - linux-dev |
Contributor
Author
|
Oh what the hell: twice on servo-linux2 |
Contributor
|
@Ms2ger disk full, please retry. |
Contributor
|
@bors-servo retry
|
Contributor
bors-servo
pushed a commit
that referenced
this pull request
Oct 6, 2016
Provide the fetched data to fetch() consumers. <!-- 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/13597) <!-- Reviewable:end -->
Contributor
|
☀️ Test successful - arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css, mac-rel-wpt1, mac-rel-wpt2, windows-dev |
31 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change is