From abbbbf01ed997c891a8fa24cf35c6bb1684b9367 Mon Sep 17 00:00:00 2001 From: Evan Lloyd New-Schmidt Date: Tue, 14 Jun 2022 15:50:18 -0400 Subject: [PATCH] Add PlatformType::current for android target --- src/types.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/types.rs b/src/types.rs index aebd32f..0cd82d0 100644 --- a/src/types.rs +++ b/src/types.rs @@ -68,6 +68,11 @@ impl PlatformType { Self::Windows } + #[cfg(target_os = "android")] + pub fn current() -> Self { + Self::Android + } + #[cfg(not(any( target_os = "linux", target_os = "macos", @@ -75,7 +80,8 @@ impl PlatformType { target_os = "netbsd", target_os = "openbsd", target_os = "dragonfly", - target_os = "windows" + target_os = "windows", + target_os = "android", )))] pub fn current() -> Self { Self::Other