3 #![feature(rustc_attrs)]
12 let p = Point { x: 10, y: 10 };
13 let q = Point { x: 10, y: 10 };
15 let c = #[rustc_capture_analysis]
16 //~^ ERROR: attributes on expressions are experimental
17 //~| NOTE: see issue #15701 <https://github.com/rust-lang/rust/issues/15701>
19 //~^ First Pass analysis includes:
20 //~| Min Capture analysis includes:
22 //~^ NOTE: Capturing p[] -> ImmBorrow
23 //~| NOTE: Min Capture p[] -> ImmBorrow
24 println!("{:?}", p.x);
25 //~^ NOTE: Capturing p[(0, 0)] -> ImmBorrow
27 println!("{:?}", q.x);
28 //~^ NOTE: Capturing q[(0, 0)] -> ImmBorrow
30 //~^ NOTE: Capturing q[] -> ImmBorrow
31 //~| NOTE: Min Capture q[] -> ImmBorrow