Skip to content

Commit

Permalink
Remove Cranelift's OutOfBounds trap, which is no longer used.
Browse files Browse the repository at this point in the history
  • Loading branch information
sunfishcode committed May 1, 2020
1 parent 8393412 commit 6dd85ef
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 6 deletions.
5 changes: 0 additions & 5 deletions cranelift/codegen/src/ir/trapcode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ pub enum TrapCode {
/// A `table_addr` instruction detected an out-of-bounds error.
TableOutOfBounds,

/// Other bounds checking error.
OutOfBounds,

/// Indirect call to a null table entry.
IndirectCallToNull,

Expand Down Expand Up @@ -63,7 +60,6 @@ impl Display for TrapCode {
StackOverflow => "stk_ovf",
HeapOutOfBounds => "heap_oob",
TableOutOfBounds => "table_oob",
OutOfBounds => "oob",
IndirectCallToNull => "icall_null",
BadSignature => "bad_sig",
IntegerOverflow => "int_ovf",
Expand All @@ -86,7 +82,6 @@ impl FromStr for TrapCode {
"stk_ovf" => Ok(StackOverflow),
"heap_oob" => Ok(HeapOutOfBounds),
"table_oob" => Ok(TableOutOfBounds),
"oob" => Ok(OutOfBounds),
"icall_null" => Ok(IndirectCallToNull),
"bad_sig" => Ok(BadSignature),
"int_ovf" => Ok(IntegerOverflow),
Expand Down
1 change: 0 additions & 1 deletion crates/api/src/trap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ impl Trap {
StackOverflow => "call stack exhausted",
HeapOutOfBounds => "out of bounds memory access",
TableOutOfBounds => "undefined element: out of bounds table access",
OutOfBounds => "out of bounds",
IndirectCallToNull => "uninitialized element",
BadSignature => "indirect call type mismatch",
IntegerOverflow => "integer overflow",
Expand Down

0 comments on commit 6dd85ef

Please sign in to comment.