Backed out changeset eee17e1b0435 (bug 1538101) for Browser-chrome and DT failures. CLOSED TREE
authorDorel Luca <dluca@mozilla.com>
Wed, 08 May 2019 18:21:30 +0300
changeset 531889 616fc2abbbec6c4e8d0bcf00ee682745c24674bb
parent 531888 b5a3f0b9ce243f5cb610ee849d35637d3402c35b
child 531890 3bf1f379d77e758092f84df765e8c8726b0f3b98
push id11265
push userffxbld-merge
push dateMon, 13 May 2019 10:53:39 +0000
treeherdermozilla-beta@77e0fe8dbdd3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1538101
milestone68.0a1
backs outeee17e1b043502d063b1d609bd98750e91c1bc00
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out changeset eee17e1b0435 (bug 1538101) for Browser-chrome and DT failures. CLOSED TREE
servo/components/style/properties/declaration_block.rs
--- a/servo/components/style/properties/declaration_block.rs
+++ b/servo/components/style/properties/declaration_block.rs
@@ -1323,51 +1323,31 @@ impl<'a, 'b, 'i> DeclarationParser<'i> f
     }
 }
 
 type SmallParseErrorVec<'i> = SmallVec<[(ParseError<'i>, &'i str, Option<PropertyId>); 2]>;
 
 #[cold]
 fn report_one_css_error<'i>(
     context: &ParserContext,
-    block: Option<&PropertyDeclarationBlock>,
+    _block: Option<&PropertyDeclarationBlock>,
     selectors: Option<&SelectorList<SelectorImpl>>,
     mut error: ParseError<'i>,
     slice: &str,
     property: Option<PropertyId>,
 ) {
     debug_assert!(context.error_reporting_enabled());
 
-    fn all_properties_in_block(block: &PropertyDeclarationBlock, property: &PropertyId) -> bool {
-        match *property {
-            PropertyId::LonghandAlias(id, _) |
-            PropertyId::Longhand(id) => block.contains(id),
-            PropertyId::ShorthandAlias(id, _) |
-            PropertyId::Shorthand(id) => {
-                id.longhands().all(|longhand| block.contains(longhand))
-            },
-            // NOTE(emilio): We could do this, but it seems of limited utility,
-            // and it's linear on the size of the declaration block, so let's
-            // not.
-            PropertyId::Custom(..) => false,
-        }
-    }
-
     // If the unrecognized property looks like a vendor-specific property,
     // silently ignore it instead of polluting the error output.
     if let ParseErrorKind::Custom(StyleParseErrorKind::UnknownVendorProperty) = error.kind {
         return;
     }
 
     if let Some(ref property) = property {
-        if let Some(block) = block {
-            if all_properties_in_block(block, property) {
-                return;
-            }
-        }
         error = match *property {
             PropertyId::Custom(ref c) => StyleParseErrorKind::new_invalid(format!("--{}", c), error),
             _ => StyleParseErrorKind::new_invalid(property.non_custom_id().unwrap().name(), error),
         };
     }
 
     let location = error.location;
     let error = ContextualParseError::UnsupportedPropertyDeclaration(slice, error, selectors);