diff options
| author | bors <bors@rust-lang.org> | 2014-10-01 09:22:15 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-10-01 09:22:15 +0000 |
| commit | ff2616e847ddf913e007d715732b5669b0f22672 (patch) | |
| tree | e279e0568b2bc92c8f99d01a02a45a3a1fe040ee /src/libstd/rt | |
| parent | 60e7317345f246a8169bbfe721473f693d54cade (diff) | |
| parent | b4909f6eb713b51c73010e888053a1aed7b8fb64 (diff) | |
| download | rust-ff2616e847ddf913e007d715732b5669b0f22672.tar.gz rust-ff2616e847ddf913e007d715732b5669b0f22672.zip | |
auto merge of #17630 : sfackler/rust/cfg-warnings, r=brson
Closes #17490
Diffstat (limited to 'src/libstd/rt')
| -rw-r--r-- | src/libstd/rt/backtrace.rs | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/libstd/rt/backtrace.rs b/src/libstd/rt/backtrace.rs index aa9505d83fc..33f8713e1a1 100644 --- a/src/libstd/rt/backtrace.rs +++ b/src/libstd/rt/backtrace.rs @@ -253,7 +253,7 @@ mod imp { /// play well with green threads, so while it is extremely nice /// and simple to use it should be used only on iOS devices as the /// only viable option. - #[cfg(target_os = "ios", target_arch = "arm")] + #[cfg(all(target_os = "ios", target_arch = "arm"))] #[inline(never)] pub fn write(w: &mut Writer) -> IoResult<()> { use iter::{Iterator, range}; @@ -284,7 +284,7 @@ mod imp { result::fold(iter, (), |_, _| ()) } - #[cfg(not(target_os = "ios", target_arch = "arm"))] + #[cfg(not(all(target_os = "ios", target_arch = "arm")))] #[inline(never)] // if we know this is a function call, we can skip it when // tracing pub fn write(w: &mut Writer) -> IoResult<()> { @@ -365,8 +365,7 @@ mod imp { } } - #[cfg(target_os = "macos")] - #[cfg(target_os = "ios")] + #[cfg(any(target_os = "macos", target_os = "ios"))] fn print(w: &mut Writer, idx: int, addr: *mut libc::c_void) -> IoResult<()> { use intrinsics; #[repr(C)] @@ -391,7 +390,7 @@ mod imp { } } - #[cfg(not(target_os = "macos"), not(target_os = "ios"))] + #[cfg(not(any(target_os = "macos", target_os = "ios")))] fn print(w: &mut Writer, idx: int, addr: *mut libc::c_void) -> IoResult<()> { use collections::Collection; use iter::Iterator; @@ -571,16 +570,17 @@ mod imp { extern { // No native _Unwind_Backtrace on iOS - #[cfg(not(target_os = "ios", target_arch = "arm"))] + #[cfg(not(all(target_os = "ios", target_arch = "arm")))] pub fn _Unwind_Backtrace(trace: _Unwind_Trace_Fn, trace_argument: *mut libc::c_void) -> _Unwind_Reason_Code; - #[cfg(not(target_os = "android"), - not(target_os = "linux", target_arch = "arm"))] + #[cfg(all(not(target_os = "android"), + not(all(target_os = "linux", target_arch = "arm"))))] pub fn _Unwind_GetIP(ctx: *mut _Unwind_Context) -> libc::uintptr_t; - #[cfg(not(target_os = "android"), - not(target_os = "linux", target_arch = "arm"))] + + #[cfg(all(not(target_os = "android"), + not(all(target_os = "linux", target_arch = "arm"))))] pub fn _Unwind_FindEnclosingFunction(pc: *mut libc::c_void) -> *mut libc::c_void; } @@ -588,8 +588,8 @@ mod imp { // On android, the function _Unwind_GetIP is a macro, and this is the // expansion of the macro. This is all copy/pasted directly from the // header file with the definition of _Unwind_GetIP. - #[cfg(target_os = "android")] - #[cfg(target_os = "linux", target_arch = "arm")] + #[cfg(any(target_os = "android", + all(target_os = "linux", target_arch = "arm")))] pub unsafe fn _Unwind_GetIP(ctx: *mut _Unwind_Context) -> libc::uintptr_t { #[repr(C)] enum _Unwind_VRS_Result { @@ -634,8 +634,8 @@ mod imp { // This function also doesn't exist on Android or ARM/Linux, so make it // a no-op - #[cfg(target_os = "android")] - #[cfg(target_os = "linux", target_arch = "arm")] + #[cfg(any(target_os = "android", + all(target_os = "linux", target_arch = "arm")))] pub unsafe fn _Unwind_FindEnclosingFunction(pc: *mut libc::c_void) -> *mut libc::c_void { |
