mirror of
https://github.com/leptos-rs/leptos.git
synced 2025-12-27 09:54:41 -05:00
fix: clippy errors (#3772)
* fix: use map instead of if else * fix: needless lifetime
This commit is contained in:
@@ -63,7 +63,7 @@ delegate_impl_len!(<T,> Vec<T>);
|
||||
delegate_impl_len!(str);
|
||||
delegate_impl_len!(String);
|
||||
|
||||
impl<'a> Len for Cow<'a, str> {
|
||||
impl Len for Cow<'_, str> {
|
||||
#[inline(always)]
|
||||
fn len(&self) -> usize {
|
||||
<str>::len(self)
|
||||
@@ -75,7 +75,7 @@ impl<'a> Len for Cow<'a, str> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> Len for &Cow<'a, str> {
|
||||
impl Len for &Cow<'_, str> {
|
||||
#[inline(always)]
|
||||
fn len(&self) -> usize {
|
||||
Len::len(*self)
|
||||
@@ -87,7 +87,7 @@ impl<'a> Len for &Cow<'a, str> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> Len for &mut Cow<'a, str> {
|
||||
impl Len for &mut Cow<'_, str> {
|
||||
#[inline(always)]
|
||||
fn len(&self) -> usize {
|
||||
Len::len(*self)
|
||||
@@ -99,7 +99,7 @@ impl<'a> Len for &mut Cow<'a, str> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a, T> Len for Cow<'a, [T]>
|
||||
impl<T> Len for Cow<'_, [T]>
|
||||
where
|
||||
[T]: ToOwned,
|
||||
{
|
||||
@@ -114,7 +114,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a, T> Len for &Cow<'a, [T]>
|
||||
impl<T> Len for &Cow<'_, [T]>
|
||||
where
|
||||
[T]: ToOwned,
|
||||
{
|
||||
@@ -129,7 +129,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a, T> Len for &mut Cow<'a, [T]>
|
||||
impl<T> Len for &mut Cow<'_, [T]>
|
||||
where
|
||||
[T]: ToOwned,
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user