diff options
Diffstat (limited to 'src/libstd/dynamic_lib.rs')
| -rw-r--r-- | src/libstd/dynamic_lib.rs | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/libstd/dynamic_lib.rs b/src/libstd/dynamic_lib.rs index a88448f47e0..bd2bd1ad090 100644 --- a/src/libstd/dynamic_lib.rs +++ b/src/libstd/dynamic_lib.rs @@ -154,7 +154,7 @@ impl DynamicLibrary { } } -#[cfg(test, not(target_os = "ios"))] +#[cfg(all(test, not(target_os = "ios")))] mod test { use super::*; use prelude::*; @@ -189,10 +189,10 @@ mod test { } #[test] - #[cfg(target_os = "linux")] - #[cfg(target_os = "macos")] - #[cfg(target_os = "freebsd")] - #[cfg(target_os = "dragonfly")] + #[cfg(any(target_os = "linux", + target_os = "macos", + target_os = "freebsd", + target_os = "dragonfly"))] fn test_errors_do_not_crash() { // Open /dev/null as a library to get an error, and make sure // that only causes an error, and not a crash. @@ -204,12 +204,12 @@ mod test { } } -#[cfg(target_os = "linux")] -#[cfg(target_os = "android")] -#[cfg(target_os = "macos")] -#[cfg(target_os = "ios")] -#[cfg(target_os = "freebsd")] -#[cfg(target_os = "dragonfly")] +#[cfg(any(target_os = "linux", + target_os = "android", + target_os = "macos", + target_os = "ios", + target_os = "freebsd", + target_os = "dragonfly"))] pub mod dl { use c_str::{CString, ToCStr}; |
