diff --git a/src/lib.rs b/src/lib.rs index a090962..0d5a745 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -528,7 +528,9 @@ impl<'a> StyleSheetParser<'a> { Expr::Style(s) => stmts.push(Stmt::Style(s)), Expr::AtRule(a) => match a { AtRule::For(s) => stmts.extend(s), - AtRule::Content => return Err("@content is only allowed within mixin declarations.".into()), + AtRule::Content => { + return Err("@content is only allowed within mixin declarations.".into()) + } r => stmts.push(Stmt::AtRule(r)), }, Expr::Styles(s) => stmts.extend(s.into_iter().map(Box::new).map(Stmt::Style)), @@ -694,7 +696,9 @@ pub(crate) fn eat_expr>( AtRule::Warn(a, b) => Ok(Some(Expr::Warn(a, b))), AtRule::Error(pos, err) => Err(SassError::new(err, pos)), AtRule::Return(_) => todo!("@return in unexpected location!"), - AtRule::Content => return Err("@content is only allowed within mixin declarations.".into()), + AtRule::Content => { + return Err("@content is only allowed within mixin declarations.".into()) + } f @ AtRule::For(..) => Ok(Some(Expr::AtRule(f))), u @ AtRule::Unknown(..) => Ok(Some(Expr::AtRule(u))), }; diff --git a/src/mixin.rs b/src/mixin.rs index c91b849..082c2fa 100644 --- a/src/mixin.rs +++ b/src/mixin.rs @@ -98,7 +98,7 @@ impl Mixin { match expr { Expr::AtRule(a) => match a { AtRule::Content => todo!("@content in mixin"), - _ => stmts.push(Stmt::AtRule(a)) + _ => stmts.push(Stmt::AtRule(a)), }, Expr::Style(s) => stmts.push(Stmt::Style(s)), Expr::Styles(s) => stmts.extend(s.into_iter().map(Box::new).map(Stmt::Style)),