diff options
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/rt.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/libcore/rt.rs b/src/libcore/rt.rs index 9bc83a5f904..04a8ee30235 100644 --- a/src/libcore/rt.rs +++ b/src/libcore/rt.rs @@ -34,9 +34,12 @@ extern mod rustrt { // 'rt_', otherwise the compiler won't find it. To fix this, see // gather_rust_rtcalls. #[rt(fail_)] -pub fn rt_fail_(expr: *c_char, file: *c_char, line: size_t) { - cleanup_stack_for_failure(); - rustrt::rust_upcall_fail(expr, file, line); +pub fn rt_fail_(expr: *c_char, file: *c_char, line: size_t) -> ! { + unsafe { + cleanup_stack_for_failure(); + rustrt::rust_upcall_fail(expr, file, line); + cast::transmute(()) + } } #[rt(fail_bounds_check)] |
