Make UnwindTraceFn take &UnwindContext
only
This commit is contained in:
parent
2f9e374431
commit
f5ef1d145e
@ -78,7 +78,7 @@ pub struct UnwindException {
|
||||
}
|
||||
|
||||
pub type UnwindTraceFn =
|
||||
extern "C" fn(ctx: &mut UnwindContext<'_>, arg: *mut c_void) -> UnwindReasonCode;
|
||||
extern "C" fn(ctx: &UnwindContext<'_>, arg: *mut c_void) -> UnwindReasonCode;
|
||||
|
||||
#[cfg(not(feature = "unwinder"))]
|
||||
#[repr(C)]
|
||||
|
@ -60,7 +60,7 @@ fn stack_trace() {
|
||||
counter: usize,
|
||||
}
|
||||
extern "C" fn callback(
|
||||
unwind_ctx: &mut UnwindContext<'_>,
|
||||
unwind_ctx: &UnwindContext<'_>,
|
||||
arg: *mut c_void,
|
||||
) -> UnwindReasonCode {
|
||||
let data = unsafe { &mut *(arg as *mut CallbackData) };
|
||||
|
@ -390,7 +390,7 @@ pub extern "C-unwind" fn _Unwind_Backtrace(
|
||||
let frame = try1!(Frame::from_context(&ctx, signal));
|
||||
if !skipping {
|
||||
let code = trace(
|
||||
&mut UnwindContext {
|
||||
&UnwindContext {
|
||||
frame: frame.as_ref(),
|
||||
ctx: &mut ctx,
|
||||
signal,
|
||||
|
Loading…
Reference in New Issue
Block a user