mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
Parse at-rule without block in two stages
This commit is contained in:
parent
09df9c4316
commit
2bca62045f
19 changed files with 133 additions and 106 deletions
|
@ -476,9 +476,9 @@ pub fn parse_keyframe_list<R>(
|
|||
}).filter_map(Result::ok).collect()
|
||||
}
|
||||
|
||||
enum Void {}
|
||||
impl<'a, 'i, R> AtRuleParser<'i> for KeyframeListParser<'a, R> {
|
||||
type Prelude = Void;
|
||||
type PreludeNoBlock = ();
|
||||
type PreludeBlock = ();
|
||||
type AtRule = Arc<Locked<Keyframe>>;
|
||||
type Error = SelectorParseError<'i, StyleParseError<'i>>;
|
||||
}
|
||||
|
@ -543,7 +543,8 @@ struct KeyframeDeclarationParser<'a, 'b: 'a> {
|
|||
|
||||
/// Default methods reject all at rules.
|
||||
impl<'a, 'b, 'i> AtRuleParser<'i> for KeyframeDeclarationParser<'a, 'b> {
|
||||
type Prelude = ();
|
||||
type PreludeNoBlock = ();
|
||||
type PreludeBlock = ();
|
||||
type AtRule = ();
|
||||
type Error = SelectorParseError<'i, StyleParseError<'i>>;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue