Remove unnecessary lifetime specifiers
This commit is contained in:
parent
44df5a8621
commit
ea525648ae
8 changed files with 9 additions and 9 deletions
|
@ -32,7 +32,7 @@ impl From<DateTime<Utc>> for Datetime {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Datetime {
|
||||
impl From<&str> for Datetime {
|
||||
fn from(s: &str) -> Self {
|
||||
match datetime_raw(s) {
|
||||
Ok((_, v)) => v,
|
||||
|
|
|
@ -37,7 +37,7 @@ impl From<String> for Duration {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Duration {
|
||||
impl From<&str> for Duration {
|
||||
fn from(s: &str) -> Self {
|
||||
match duration(s) {
|
||||
Ok((_, v)) => v,
|
||||
|
|
|
@ -30,13 +30,13 @@ impl From<String> for Ident {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Ident {
|
||||
impl From<&str> for Ident {
|
||||
fn from(i: &str) -> Ident {
|
||||
Ident(String::from(i))
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a String> for Ident {
|
||||
impl From<&String> for Ident {
|
||||
fn from(i: &String) -> Ident {
|
||||
Ident(String::from(i))
|
||||
}
|
||||
|
|
|
@ -106,7 +106,7 @@ impl From<f64> for Number {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Number {
|
||||
impl From<&str> for Number {
|
||||
fn from(s: &str) -> Self {
|
||||
Number::Decimal(BigDecimal::from_str(s).unwrap_or_default())
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@ use std::str;
|
|||
#[derive(Clone, Debug, Default, Eq, Ord, PartialEq, PartialOrd, Serialize, Deserialize)]
|
||||
pub struct Regex(String);
|
||||
|
||||
impl<'a> From<&'a str> for Regex {
|
||||
impl From<&str> for Regex {
|
||||
fn from(r: &str) -> Regex {
|
||||
Regex(r.replace("\\/", "/"))
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ impl From<String> for Script {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Script {
|
||||
impl From<&str> for Script {
|
||||
fn from(s: &str) -> Self {
|
||||
Script(String::from(s))
|
||||
}
|
||||
|
|
|
@ -27,7 +27,7 @@ impl From<String> for Strand {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Strand {
|
||||
impl From<&str> for Strand {
|
||||
fn from(s: &str) -> Self {
|
||||
Strand(String::from(s))
|
||||
}
|
||||
|
|
|
@ -312,7 +312,7 @@ impl From<String> for Value {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> From<&'a str> for Value {
|
||||
impl From<&str> for Value {
|
||||
fn from(v: &str) -> Self {
|
||||
Value::Strand(Strand::from(v))
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue