diff --git a/components/style/stylesheets.rs b/components/style/stylesheets.rs index 71f9e2a71ef..3e90a1fbec5 100644 --- a/components/style/stylesheets.rs +++ b/components/style/stylesheets.rs @@ -170,21 +170,6 @@ impl ToCss for StyleRule { impl Stylesheet { - pub fn from_bytes_iter>>( - input: I, base_url: ServoUrl, protocol_encoding_label: Option<&str>, - environment_encoding: Option, origin: Origin, - error_reporter: Box, - extra_data: ParserContextExtraData) -> Stylesheet { - let mut bytes = vec![]; - // TODO: incremental decoding and tokenization/parsing - for chunk in input { - bytes.extend_from_slice(&chunk) - } - Stylesheet::from_bytes(&bytes, base_url, protocol_encoding_label, - environment_encoding, origin, error_reporter, - extra_data) - } - pub fn from_bytes(bytes: &[u8], base_url: ServoUrl, protocol_encoding_label: Option<&str>, @@ -192,7 +177,6 @@ impl Stylesheet { origin: Origin, error_reporter: Box, extra_data: ParserContextExtraData) -> Stylesheet { - // TODO: bytes.as_slice could be bytes.container_as_bytes() let (string, _) = decode_stylesheet_bytes( bytes, protocol_encoding_label, environment_encoding); Stylesheet::from_str(&string, base_url, origin, error_reporter, extra_data)