(
fd: i32,
thread_id: u64,
is_current: bool,
frames: &[rustpython_vm::vm::FramePtr],
)
| 348 | /// Each `FramePtr` must point to a live frame (caller holds the Mutex). |
| 349 | #[cfg(all(any(unix, windows), feature = "threading"))] |
| 350 | fn dump_traceback_thread_frames( |
| 351 | fd: i32, |
| 352 | thread_id: u64, |
| 353 | is_current: bool, |
| 354 | frames: &[rustpython_vm::vm::FramePtr], |
| 355 | ) { |
| 356 | write_thread_id(fd, thread_id, is_current); |
| 357 | |
| 358 | if frames.is_empty() { |
| 359 | puts(fd, " <no Python frame>\n"); |
| 360 | } else { |
| 361 | for fp in frames.iter().rev() { |
| 362 | // SAFETY: caller holds the Mutex, so the owning thread can't pop. |
| 363 | dump_frame_from_ref(fd, unsafe { fp.as_ref() }); |
| 364 | } |
| 365 | } |
| 366 | } |
| 367 | |
| 368 | #[derive(FromArgs)] |
| 369 | struct DumpTracebackArgs { |
no test coverage detected