diff --git a/serde/src/de/impls.rs b/serde/src/de/impls.rs index c85aa30d0..303d0516d 100644 --- a/serde/src/de/impls.rs +++ b/serde/src/de/impls.rs @@ -1717,7 +1717,6 @@ macro_rules! deserialize_enum { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl<'de> Deserialize<'de> for net::IpAddr { fn deserialize(deserializer: D) -> Result where @@ -1738,13 +1737,11 @@ impl<'de> Deserialize<'de> for net::IpAddr { parse_ip_impl! { #[cfg(any(feature = "std", not(no_core_net)))] - #[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] net::Ipv4Addr, "IPv4 address", 4 } parse_ip_impl! { #[cfg(any(feature = "std", not(no_core_net)))] - #[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] net::Ipv6Addr, "IPv6 address", 16 } @@ -1771,7 +1768,6 @@ macro_rules! parse_socket_impl { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl<'de> Deserialize<'de> for net::SocketAddr { fn deserialize(deserializer: D) -> Result where @@ -1792,14 +1788,12 @@ impl<'de> Deserialize<'de> for net::SocketAddr { parse_socket_impl! { #[cfg(any(feature = "std", not(no_core_net)))] - #[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] net::SocketAddrV4, "IPv4 socket address", |(ip, port)| net::SocketAddrV4::new(ip, port), } parse_socket_impl! { #[cfg(any(feature = "std", not(no_core_net)))] - #[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] net::SocketAddrV6, "IPv6 socket address", |(ip, port)| net::SocketAddrV6::new(ip, port, 0, 0), } diff --git a/serde/src/ser/impls.rs b/serde/src/ser/impls.rs index 235c9cdeb..fb574eae1 100644 --- a/serde/src/ser/impls.rs +++ b/serde/src/ser/impls.rs @@ -784,7 +784,6 @@ macro_rules! serialize_display_bounded_length { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::IpAddr { fn serialize(&self, serializer: S) -> Result where @@ -855,7 +854,6 @@ fn test_format_u8() { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::Ipv4Addr { fn serialize(&self, serializer: S) -> Result where @@ -880,7 +878,6 @@ impl Serialize for net::Ipv4Addr { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::Ipv6Addr { fn serialize(&self, serializer: S) -> Result where @@ -897,7 +894,6 @@ impl Serialize for net::Ipv6Addr { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::SocketAddr { fn serialize(&self, serializer: S) -> Result where @@ -922,7 +918,6 @@ impl Serialize for net::SocketAddr { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::SocketAddrV4 { fn serialize(&self, serializer: S) -> Result where @@ -939,7 +934,6 @@ impl Serialize for net::SocketAddrV4 { } #[cfg(any(feature = "std", not(no_core_net)))] -#[cfg_attr(docsrs, doc(cfg(any(feature = "std", not(no_core_net)))))] impl Serialize for net::SocketAddrV6 { fn serialize(&self, serializer: S) -> Result where