mirror of
https://github.com/servo/servo.git
synced 2025-08-08 06:55:31 +01:00
style: Revert try -> r#try change.
Since we're in an inconsistent state because mako files weren't updated, and it's really really ugly.
This commit is contained in:
parent
155caba595
commit
212b3e1311
47 changed files with 326 additions and 336 deletions
|
@ -125,8 +125,8 @@ impl MediaQuery {
|
|||
input: &mut Parser<'i, 't>,
|
||||
) -> Result<Self, ParseError<'i>> {
|
||||
let (qualifier, explicit_media_type) = input
|
||||
.r#try(|input| -> Result<_, ()> {
|
||||
let qualifier = input.r#try(Qualifier::parse).ok();
|
||||
.try(|input| -> Result<_, ()> {
|
||||
let qualifier = input.try(Qualifier::parse).ok();
|
||||
let ident = input.expect_ident().map_err(|_| ())?;
|
||||
let media_type = MediaQueryType::parse(&ident)?;
|
||||
Ok((qualifier, Some(media_type)))
|
||||
|
@ -135,7 +135,7 @@ impl MediaQuery {
|
|||
|
||||
let condition = if explicit_media_type.is_none() {
|
||||
Some(MediaCondition::parse(context, input)?)
|
||||
} else if input.r#try(|i| i.expect_ident_matching("and")).is_ok() {
|
||||
} else if input.try(|i| i.expect_ident_matching("and")).is_ok() {
|
||||
Some(MediaCondition::parse_disallow_or(context, input)?)
|
||||
} else {
|
||||
None
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue