Adjust test to still show miscompile
The capture of i in assert_ne!() is now known read-only, which enables early SROA. Block this by passing i to println, where we currently cannot recognize this.
This commit is contained in:
parent
d71ed8d19b
commit
dd151beeb6
3 changed files with 3 additions and 0 deletions
|
|
@ -55,6 +55,7 @@ fn main() {
|
|||
// The `Box` has been deallocated by now, so this is a dangling reference!
|
||||
let r: &u8 = &*r;
|
||||
println!("{:p}", r);
|
||||
println!("{}", i);
|
||||
|
||||
// The following might segfault. Or it might not.
|
||||
// Depends on the platform semantics
|
||||
|
|
|
|||
|
|
@ -58,6 +58,7 @@ fn main() {
|
|||
// The `Box` has been deallocated by now, so this is a dangling reference!
|
||||
let r: &u8 = &*r;
|
||||
println!("{:p}", r);
|
||||
println!("{}", i);
|
||||
|
||||
// The following might segfault. Or it might not.
|
||||
// Depends on the platform semantics
|
||||
|
|
|
|||
|
|
@ -58,6 +58,7 @@ fn main() {
|
|||
// The `Box` has been deallocated by now, so this is a dangling reference!
|
||||
let r: &u8 = &*r;
|
||||
println!("{:p}", r);
|
||||
println!("{}", i);
|
||||
|
||||
// The following might segfault. Or it might not.
|
||||
// Depends on the platform semantics
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue