chore: Remove unnecessary lifetimes
This commit is contained in:
parent
99081fd7d2
commit
13a546056e
@ -78,7 +78,7 @@ impl<'de> Deserialize<'de> for VoipVersionId {
|
|||||||
{
|
{
|
||||||
struct CallVersionVisitor;
|
struct CallVersionVisitor;
|
||||||
|
|
||||||
impl<'de> Visitor<'de> for CallVersionVisitor {
|
impl Visitor<'_> for CallVersionVisitor {
|
||||||
type Value = VoipVersionId;
|
type Value = VoipVersionId;
|
||||||
|
|
||||||
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||||
|
@ -107,7 +107,7 @@ impl<T> Raw<T> {
|
|||||||
{
|
{
|
||||||
struct FieldVisitor<'b>(&'b str);
|
struct FieldVisitor<'b>(&'b str);
|
||||||
|
|
||||||
impl<'b, 'de> Visitor<'de> for FieldVisitor<'b> {
|
impl Visitor<'_> for FieldVisitor<'_> {
|
||||||
type Value = bool;
|
type Value = bool;
|
||||||
|
|
||||||
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||||
@ -124,7 +124,7 @@ impl<T> Raw<T> {
|
|||||||
|
|
||||||
struct Field<'b>(&'b str);
|
struct Field<'b>(&'b str);
|
||||||
|
|
||||||
impl<'b, 'de> DeserializeSeed<'de> for Field<'b> {
|
impl<'de> DeserializeSeed<'de> for Field<'_> {
|
||||||
type Value = bool;
|
type Value = bool;
|
||||||
|
|
||||||
fn deserialize<D>(self, deserializer: D) -> Result<bool, D::Error>
|
fn deserialize<D>(self, deserializer: D) -> Result<bool, D::Error>
|
||||||
@ -146,7 +146,7 @@ impl<T> Raw<T> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'b, 'de, T> Visitor<'de> for SingleFieldVisitor<'b, T>
|
impl<'de, T> Visitor<'de> for SingleFieldVisitor<'_, T>
|
||||||
where
|
where
|
||||||
T: Deserialize<'de>,
|
T: Deserialize<'de>,
|
||||||
{
|
{
|
||||||
|
@ -60,7 +60,7 @@ where
|
|||||||
{
|
{
|
||||||
struct F64OrStringVisitor;
|
struct F64OrStringVisitor;
|
||||||
|
|
||||||
impl<'de> Visitor<'de> for F64OrStringVisitor {
|
impl Visitor<'_> for F64OrStringVisitor {
|
||||||
type Value = f64;
|
type Value = f64;
|
||||||
|
|
||||||
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||||
@ -134,7 +134,7 @@ where
|
|||||||
{
|
{
|
||||||
struct IntOrStringVisitor;
|
struct IntOrStringVisitor;
|
||||||
|
|
||||||
impl<'de> Visitor<'de> for IntOrStringVisitor {
|
impl Visitor<'_> for IntOrStringVisitor {
|
||||||
type Value = Int;
|
type Value = Int;
|
||||||
|
|
||||||
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||||
|
@ -31,7 +31,7 @@ pub enum MembershipData<'a> {
|
|||||||
Session(&'a SessionMembershipData),
|
Session(&'a SessionMembershipData),
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> MembershipData<'a> {
|
impl MembershipData<'_> {
|
||||||
/// The application this RTC membership participates in (the session type, can be `m.call`...)
|
/// The application this RTC membership participates in (the session type, can be `m.call`...)
|
||||||
pub fn application(&self) -> &Application {
|
pub fn application(&self) -> &Application {
|
||||||
match self {
|
match self {
|
||||||
|
@ -454,7 +454,7 @@ pub struct PropertiesNames<'a> {
|
|||||||
pub properties: &'a [&'static str],
|
pub properties: &'a [&'static str],
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> PropertiesNames<'a> {
|
impl PropertiesNames<'_> {
|
||||||
fn to_tuple(self) -> (&'static str, HashSet<&'static str>) {
|
fn to_tuple(self) -> (&'static str, HashSet<&'static str>) {
|
||||||
let set = self.properties.iter().copied().collect();
|
let set = self.properties.iter().copied().collect();
|
||||||
(self.parent, set)
|
(self.parent, set)
|
||||||
@ -471,7 +471,7 @@ pub struct ElementAttributesReplacement<'a> {
|
|||||||
pub replacements: &'a [NameReplacement],
|
pub replacements: &'a [NameReplacement],
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> ElementAttributesReplacement<'a> {
|
impl ElementAttributesReplacement<'_> {
|
||||||
fn to_tuple(self) -> (&'static str, HashMap<&'static str, &'static str>) {
|
fn to_tuple(self) -> (&'static str, HashMap<&'static str, &'static str>) {
|
||||||
let map = self.replacements.iter().map(|r| r.to_tuple()).collect();
|
let map = self.replacements.iter().map(|r| r.to_tuple()).collect();
|
||||||
(self.element, map)
|
(self.element, map)
|
||||||
@ -490,7 +490,7 @@ pub struct ElementAttributesSchemes<'a> {
|
|||||||
pub attr_schemes: &'a [PropertiesNames<'a>],
|
pub attr_schemes: &'a [PropertiesNames<'a>],
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> ElementAttributesSchemes<'a> {
|
impl ElementAttributesSchemes<'_> {
|
||||||
fn to_tuple(self) -> (&'static str, HashMap<&'static str, HashSet<&'static str>>) {
|
fn to_tuple(self) -> (&'static str, HashMap<&'static str, HashSet<&'static str>>) {
|
||||||
let map = self.attr_schemes.iter().map(|s| s.to_tuple()).collect();
|
let map = self.attr_schemes.iter().map(|s| s.to_tuple()).collect();
|
||||||
(self.element, map)
|
(self.element, map)
|
||||||
|
@ -300,7 +300,7 @@ where
|
|||||||
event_id: &'a Id,
|
event_id: &'a Id,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a, Id> Ord for TieBreaker<'a, Id>
|
impl<Id> Ord for TieBreaker<'_, Id>
|
||||||
where
|
where
|
||||||
Id: Ord,
|
Id: Ord,
|
||||||
{
|
{
|
||||||
@ -320,7 +320,7 @@ where
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a, Id> PartialOrd for TieBreaker<'a, Id>
|
impl<Id> PartialOrd for TieBreaker<'_, Id>
|
||||||
where
|
where
|
||||||
Id: Ord,
|
Id: Ord,
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user