mirror of
https://github.com/servo/servo.git
synced 2025-08-09 15:35:34 +01:00
Make PropertyDeclaration::parse return an enum rather than push to a Vec.
This commit is contained in:
parent
8160490272
commit
9d663ea7af
6 changed files with 83 additions and 113 deletions
|
@ -211,13 +211,8 @@ impl Declaration {
|
|||
return false
|
||||
};
|
||||
let mut input = Parser::new(&self.val);
|
||||
let mut list = Vec::new();
|
||||
let res = PropertyDeclaration::parse(id, cx, &mut input,
|
||||
&mut list, /* in_keyframe */ false);
|
||||
let res = PropertyDeclaration::parse(id, cx, &mut input, /* in_keyframe */ false);
|
||||
let _ = input.try(parse_important);
|
||||
if !input.is_exhausted() {
|
||||
return false;
|
||||
}
|
||||
res.is_ok()
|
||||
res.is_ok() && input.is_exhausted()
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue