Auto merge of #17353 - upsuper:counter-style-disc, r=dbaron

Make counter style 'disc' not overridable

This is the Servo side change for [bug 1372488](https://bugzilla.mozilla.org/show_bug.cgi?id=1372488).

<!-- 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/17353)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2017-06-15 23:51:16 -07:00 committed by GitHub
commit 32f82959f8

View file

@ -365,10 +365,10 @@ impl<'a, 'b, 'i> AtRuleParser<'i> for NestedRuleParser<'a, 'b> {
return Err(StyleParseError::UnsupportedAtRule(name.clone()).into())
}
let name = parse_counter_style_name(input)?;
// ASCII-case-insensitive matches for "decimal" are already
// lower-cased by `parse_counter_style_name`, so we can use ==
// here.
if name.0 == atom!("decimal") {
// ASCII-case-insensitive matches for "decimal" and "disc".
// The name is already lower-cased by `parse_counter_style_name`
// so we can use == here.
if name.0 == atom!("decimal") || name.0 == atom!("disc") {
return Err(StyleParseError::UnspecifiedError.into())
}
Ok(AtRuleType::WithBlock(AtRulePrelude::CounterStyle(name)))