Skip to content

Commit

Permalink
Remove rustc_middle::mir::interpret::CheckInAllocMsg::NullPointerTest
Browse files Browse the repository at this point in the history
  • Loading branch information
hyd-dev committed May 4, 2021
1 parent c20c921 commit ee7a6c6
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions compiler/rustc_middle/src/mir/interpret/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@ impl fmt::Display for InvalidProgramInfo<'_> {
#[derive(Debug, Copy, Clone, TyEncodable, TyDecodable, HashStable)]
pub enum CheckInAllocMsg {
MemoryAccessTest,
NullPointerTest,
PointerArithmeticTest,
InboundsTest,
}
Expand All @@ -185,7 +184,6 @@ impl fmt::Display for CheckInAllocMsg {
"{}",
match *self {
CheckInAllocMsg::MemoryAccessTest => "memory access",
CheckInAllocMsg::NullPointerTest => "null pointer test",
CheckInAllocMsg::PointerArithmeticTest => "pointer arithmetic",
CheckInAllocMsg::InboundsTest => "inbounds test",
}
Expand Down Expand Up @@ -308,9 +306,6 @@ impl fmt::Display for UndefinedBehaviorInfo<'_> {
ptr.alloc_id,
allocation_size.bytes()
),
DanglingIntPointer(_, CheckInAllocMsg::NullPointerTest) => {
write!(f, "null pointer is not allowed for this operation")
}
DanglingIntPointer(i, msg) => {
write!(f, "{} failed: 0x{:x} is not a valid pointer", msg, i)
}
Expand Down

0 comments on commit ee7a6c6

Please sign in to comment.