mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-28 23:53:55 +00:00
Remove unused trap_unimplemented_ret_value
This commit is contained in:
parent
8dc71a419e
commit
d2b8406c20
11
src/trap.rs
11
src/trap.rs
@ -68,14 +68,3 @@ pub(crate) fn trap_unimplemented(fx: &mut FunctionCx<'_, '_, impl Module>, msg:
|
||||
fx.bcx.ins().trapnz(true_, TrapCode::User(!0));
|
||||
}
|
||||
|
||||
/// Like `trap_unimplemented` but returns a fake value of the specified type.
|
||||
///
|
||||
/// Trap code: user65535
|
||||
pub(crate) fn trap_unimplemented_ret_value<'tcx>(
|
||||
fx: &mut FunctionCx<'_, 'tcx, impl Module>,
|
||||
dest_layout: TyAndLayout<'tcx>,
|
||||
msg: impl AsRef<str>,
|
||||
) -> CValue<'tcx> {
|
||||
trap_unimplemented(fx, msg);
|
||||
CValue::by_ref(Pointer::const_addr(fx, 0), dest_layout)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user