This should be preferred to the libc `abort` function.
}
match name {
+ "abort" => {
+ let llfn = bcx.ccx().intrinsics.get_copy(&("llvm.trap"));
+ Call(bcx, llfn, [], []);
+ RetVoid(bcx);
+ }
"size_of" => {
let tp_ty = substs.tys[0];
let lltp_ty = type_of::type_of(ccx, tp_ty);
} else {
match name {
+ "abort" => (0, ~[], ty::mk_bot()),
"size_of" |
"pref_align_of" | "min_align_of" => (1u, ~[], ty::mk_uint()),
"init" => (1u, ~[], param(ccx, 0u)),
}
extern "rust-intrinsic" {
+ /// Abort the execution of the process.
+ #[cfg(not(stage0))]
+ pub fn abort() -> !;
/// Atomic compare and exchange, sequentially consistent.
pub fn atomic_cxchg(dst: &mut int, old: int, src: int) -> int;