From 2b4ff3f25b1bd5b9b3d565774dfcf9c60f132d2b Mon Sep 17 00:00:00 2001 From: Sebastian Imlay Date: Wed, 29 Nov 2023 12:19:06 -0500 Subject: [PATCH] Add Apple watchOS support --- tokio-util/tests/udp.rs | 4 ++-- tokio/src/net/unix/ucred.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tokio-util/tests/udp.rs b/tokio-util/tests/udp.rs index db726a3d2b6..e1170b0003b 100644 --- a/tokio-util/tests/udp.rs +++ b/tokio-util/tests/udp.rs @@ -14,7 +14,7 @@ use std::io; use std::sync::Arc; #[cfg_attr( - any(target_os = "macos", target_os = "ios", target_os = "tvos"), + any(target_os = "macos", target_os = "ios", target_os = "tvos", target_os = "watchos"), allow(unused_assignments) )] #[tokio::test] @@ -44,7 +44,7 @@ async fn send_framed_byte_codec() -> std::io::Result<()> { b_soc = b.into_inner(); } - #[cfg(not(any(target_os = "macos", target_os = "ios", target_os = "tvos")))] + #[cfg(not(any(target_os = "macos", target_os = "ios", target_os = "tvos", target_os = "watchos")))] // test sending & receiving an empty message { let mut a = UdpFramed::new(a_soc, ByteCodec); diff --git a/tokio/src/net/unix/ucred.rs b/tokio/src/net/unix/ucred.rs index dcd4deddf93..75add5e07aa 100644 --- a/tokio/src/net/unix/ucred.rs +++ b/tokio/src/net/unix/ucred.rs @@ -45,7 +45,7 @@ pub(crate) use self::impl_netbsd::get_peer_cred; #[cfg(any(target_os = "dragonfly", target_os = "freebsd"))] pub(crate) use self::impl_bsd::get_peer_cred; -#[cfg(any(target_os = "macos", target_os = "ios", target_os = "tvos"))] +#[cfg(any(target_os = "macos", target_os = "ios", target_os = "tvos", target_os = "watchos"))] pub(crate) use self::impl_macos::get_peer_cred; #[cfg(any(target_os = "solaris", target_os = "illumos"))] @@ -187,7 +187,7 @@ pub(crate) mod impl_bsd { } } -#[cfg(any(target_os = "macos", target_os = "ios", target_os = "tvos"))] +#[cfg(any(target_os = "macos", target_os = "ios", target_os = "tvos", target_os = "watchos"))] pub(crate) mod impl_macos { use crate::net::unix::{self, UnixStream};