aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bindings/trace.rs
diff options
context:
space:
mode:
authorbors-servo <lbergstrom+bors@mozilla.com>2018-03-26 17:30:36 -0400
committerGitHub <noreply@github.com>2018-03-26 17:30:36 -0400
commit1981efcc3585d244f6293716fbcf833afa58e629 (patch)
tree2a6d32df31a85660c927cd981e7e5b9787f45321 /components/script/dom/bindings/trace.rs
parent4b8416fafbbfec7f3adbc46874ea779ed90ad3d1 (diff)
parent36838d2d46ca1e8782ecabb2ad5b854ba693dac2 (diff)
downloadservo-1981efcc3585d244f6293716fbcf833afa58e629.tar.gz
servo-1981efcc3585d244f6293716fbcf833afa58e629.zip
Auto merge of #20431 - talklittle:issues-13234-5600-squashed, r=jdm
TextDecoder: streaming decode, ignoreBOM <!-- Please describe your changes on the following line: --> Implement streaming decode and ignoreBOM flag for TextDecoder. https://encoding.spec.whatwg.org/#dom-textdecoder-decode https://encoding.spec.whatwg.org/#dom-textdecoder-ignorebom --- <!-- 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 #13234 (github issue number if applicable). - [x] These changes fix #5600 (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [x] These changes do not require tests because the wpt tests are used for testing: * /encoding/textdecoder-fatal-streaming.html * /encoding/textdecoder-streaming.html * /encoding/textdecoder-ignorebom.html <!-- 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/20431) <!-- Reviewable:end -->
Diffstat (limited to 'components/script/dom/bindings/trace.rs')
-rw-r--r--components/script/dom/bindings/trace.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/components/script/dom/bindings/trace.rs b/components/script/dom/bindings/trace.rs
index be38b14a540..0fd94953e3b 100644
--- a/components/script/dom/bindings/trace.rs
+++ b/components/script/dom/bindings/trace.rs
@@ -47,7 +47,7 @@ use dom::bindings::root::{Dom, DomRoot};
use dom::bindings::str::{DOMString, USVString};
use dom::bindings::utils::WindowProxyHandler;
use dom::document::PendingRestyle;
-use encoding_rs::Encoding;
+use encoding_rs::{Decoder, Encoding};
use euclid::{Transform2D, Transform3D, Point2D, Vector2D, Rect, TypedSize2D, TypedScale};
use euclid::Length as EuclidLength;
use html5ever::{Prefix, LocalName, Namespace, QualName};
@@ -127,6 +127,9 @@ unsafe_no_jsmanaged_fields!(CSSError);
unsafe_no_jsmanaged_fields!(&'static Encoding);
+unsafe_no_jsmanaged_fields!(RefCell<Decoder>);
+unsafe_no_jsmanaged_fields!(RefCell<Vec<u8>>);
+
unsafe_no_jsmanaged_fields!(Reflector);
unsafe_no_jsmanaged_fields!(Duration);