NFC: Address Clippy `clone_on_copy`.

This commit is contained in:
Brian Smith 2023-08-30 16:26:07 -07:00
parent 3e8d10d72c
commit 177c39eee5
2 changed files with 1 additions and 2 deletions

View File

@ -26,7 +26,6 @@ cargo clippy \
\
--deny clippy::as_conversions \
\
--allow clippy::clone_on_copy \
--allow clippy::explicit_auto_deref \
--allow clippy::too_many_arguments \
$NULL

View File

@ -125,7 +125,7 @@ impl<'a> DnsNameRef<'a> {
pub fn to_owned(&self) -> DnsName {
// DnsNameRef is already guaranteed to be valid ASCII, which is a
// subset of UTF-8.
let s: &str = self.clone().into();
let s: &str = (*self).into();
DnsName(s.to_ascii_lowercase())
}
}