MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / items

Method items

cranelift/codegen/src/ir/exception_table.rs:194–204  ·  view source on GitHub ↗

Get the exception-catch items: dynamic context updates for interpreting tags, tag-associated targets, and catch-all targets.

(&self)

Source from the content-addressed store, hash-verified

192 /// interpreting tags, tag-associated targets, and catch-all
193 /// targets.
194 pub fn items(&self) -> impl Iterator<Item = ExceptionTableItem> + '_ {
195 self.items.iter().map(|item| match item {
196 InternalExceptionTableItem::Tag(tag, target_idx) => {
197 ExceptionTableItem::Tag(*tag, self.targets[usize::try_from(*target_idx).unwrap()])
198 }
199 InternalExceptionTableItem::Default(target_idx) => {
200 ExceptionTableItem::Default(self.targets[usize::try_from(*target_idx).unwrap()])
201 }
202 InternalExceptionTableItem::Context(ctx) => ExceptionTableItem::Context(*ctx),
203 })
204 }
205
206 /// Get all branch targets.
207 pub fn all_branches(&self) -> &[BlockCall] {

Callers 4

map_exception_tableMethod · 0.80
fmtMethod · 0.80

Calls 5

TagClass · 0.50
ContextClass · 0.50
mapMethod · 0.45
iterMethod · 0.45
unwrapMethod · 0.45

Tested by

no test coverage detected