Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
bytecodealliance
GitHub Repository: bytecodealliance/wasmtime
Path: blob/main/cranelift/module/src/traps.rs
1691 views
1
//! Defines `TrapSite`.
2
3
use cranelift_codegen::{binemit, ir};
4
5
/// Record of the arguments cranelift passes to `TrapSink::trap`.
6
#[derive(Clone, Debug)]
7
pub struct TrapSite {
8
/// Offset into function.
9
pub offset: binemit::CodeOffset,
10
/// Source location given to cranelift.
11
pub srcloc: ir::SourceLoc,
12
/// Trap code, as determined by cranelift.
13
pub code: ir::TrapCode,
14
}
15
16