aboutsummaryrefslogtreecommitdiff
path: root/ctr-std/src/sys/windows/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'ctr-std/src/sys/windows/mod.rs')
-rw-r--r--ctr-std/src/sys/windows/mod.rs10
1 files changed, 7 insertions, 3 deletions
diff --git a/ctr-std/src/sys/windows/mod.rs b/ctr-std/src/sys/windows/mod.rs
index 0d12ecf..ccf79de 100644
--- a/ctr-std/src/sys/windows/mod.rs
+++ b/ctr-std/src/sys/windows/mod.rs
@@ -266,8 +266,12 @@ pub fn dur2timeout(dur: Duration) -> c::DWORD {
// handlers.
//
// https://msdn.microsoft.com/en-us/library/dn774154.aspx
-#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
+#[allow(unreachable_code)]
pub unsafe fn abort_internal() -> ! {
- asm!("int $$0x29" :: "{ecx}"(7) ::: volatile); // 7 is FAST_FAIL_FATAL_APP_EXIT
- ::intrinsics::unreachable();
+ #[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
+ {
+ asm!("int $$0x29" :: "{ecx}"(7) ::: volatile); // 7 is FAST_FAIL_FATAL_APP_EXIT
+ ::intrinsics::unreachable();
+ }
+ ::intrinsics::abort();
}