diff --git a/form_urlencoded/src/lib.rs b/form_urlencoded/src/lib.rs index 30221ad22..1d68579b7 100644 --- a/form_urlencoded/src/lib.rs +++ b/form_urlencoded/src/lib.rs @@ -396,6 +396,9 @@ pub(crate) fn encode<'a>(encoding_override: EncodingOverride<'_>, input: &'a str input.as_bytes().into() } +// std::ptr::addr_eq was stabilized in rust 1.76. Once we upgrade +// the MSRV we can remove this lint override. +#[allow(ambiguous_wide_pointer_comparisons)] pub(crate) fn decode_utf8_lossy(input: Cow<'_, [u8]>) -> Cow<'_, str> { // Note: This function is duplicated in `percent_encoding/lib.rs`. match input { diff --git a/percent_encoding/src/lib.rs b/percent_encoding/src/lib.rs index e02a43949..5e68fc9cf 100644 --- a/percent_encoding/src/lib.rs +++ b/percent_encoding/src/lib.rs @@ -447,6 +447,9 @@ impl<'a> PercentDecode<'a> { } } +// std::ptr::addr_eq was stabilized in rust 1.76. Once we upgrade +// the MSRV we can remove this lint override. +#[allow(ambiguous_wide_pointer_comparisons)] #[cfg(feature = "alloc")] fn decode_utf8_lossy(input: Cow<'_, [u8]>) -> Cow<'_, str> { // Note: This function is duplicated in `form_urlencoded/src/query_encoding.rs`.