We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3d12668 commit 6eaf4feCopy full SHA for 6eaf4fe
tests/mir-opt/copy-prop/mutate_through_pointer.rs
@@ -1,4 +1,3 @@
1
-// skip-filecheck
2
//@ test-mir-pass: CopyProp
3
//
4
// This attempts to mutate `a` via a pointer derived from `addr_of!(a)`. That is UB
@@ -18,6 +17,10 @@ use core::intrinsics::mir::*;
18
17
19
#[custom_mir(dialect = "analysis", phase = "post-cleanup")]
20
fn f(c: bool) -> bool {
+ // CHECK-LABEL: fn f(
21
+ // CHECK: _2 = copy _1;
22
+ // CHECK-NOT: _3 = &raw const _1;
23
+ // CHECK: _3 = &raw const _2;
24
mir! {
25
{
26
let a = c;
0 commit comments