Clippy fixes

This commit is contained in:
mdecimus
2024-12-01 20:13:06 +13:00
parent 4f02e4c96f
commit 03d9dabed3
27 changed files with 115 additions and 119 deletions

View File

@@ -194,7 +194,7 @@ pub trait ToNextHop {
&'x self,
domain: &'y str,
max_mx: usize,
) -> Option<Vec<NextHop<'_>>>;
) -> Option<Vec<NextHop<'x>>>;
}
impl ToNextHop for Vec<MX> {
@@ -202,7 +202,7 @@ impl ToNextHop for Vec<MX> {
&'x self,
domain: &'y str,
max_mx: usize,
) -> Option<Vec<NextHop<'_>>> {
) -> Option<Vec<NextHop<'x>>> {
if !self.is_empty() {
// Obtain max number of MX hosts to process
let mut remote_hosts = Vec::with_capacity(max_mx);

View File

@@ -218,7 +218,7 @@ pub enum NextHop<'x> {
MX(&'x str),
}
impl<'x> NextHop<'x> {
impl NextHop<'_> {
#[inline(always)]
fn hostname(&self) -> &str {
match self {