From eb6f0f345179a423eac82ed96b594f3982ee0e49 Mon Sep 17 00:00:00 2001 From: ConnorSkees <39542938+ConnorSkees@users.noreply.github.com> Date: Mon, 22 Jun 2020 12:41:59 -0400 Subject: [PATCH] remove superfluous lifetimes and returns --- src/parse/function.rs | 2 +- src/selector/extend/mod.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/parse/function.rs b/src/parse/function.rs index d6753b9..5b95614 100644 --- a/src/parse/function.rs +++ b/src/parse/function.rs @@ -18,7 +18,7 @@ use super::{NeverEmptyVec, Parser, Stmt}; const FORBIDDEN_IDENTIFIERS: [&str; 7] = ["calc", "element", "expression", "url", "and", "or", "not"]; -fn unvendor<'a>(name: &'a str) -> &'a str { +fn unvendor(name: &str) -> &str { let mut chars = name.chars(); if !matches!(chars.next(), Some('-')) { return name; diff --git a/src/selector/extend/mod.rs b/src/selector/extend/mod.rs index ef4f765..68b236e 100644 --- a/src/selector/extend/mod.rs +++ b/src/selector/extend/mod.rs @@ -166,7 +166,7 @@ impl Extender { if complex.components.len() == 1 { Ok(complex.components.first().unwrap().as_compound().clone()) } else { - return Err(("Can't extend complex selector $complex.", span).into()); + Err(("Can't extend complex selector $complex.", span).into()) } }) .collect::>>()?;