]> git.lizzy.rs Git - rust.git/blob - src/test/ui/closures/2229_closure_analysis/by_value.stderr
7014ae6a5e6af8aaa61f27af249b859f28808993
[rust.git] / src / test / ui / closures / 2229_closure_analysis / by_value.stderr
1 error[E0658]: attributes on expressions are experimental
2   --> $DIR/by_value.rs:18:13
3    |
4 LL |     let c = #[rustc_capture_analysis]
5    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
6    |
7    = note: see issue #15701 <https://github.com/rust-lang/rust/issues/15701> for more information
8    = help: add `#![feature(stmt_expr_attributes)]` to the crate attributes to enable
9
10 error: First Pass analysis includes:
11   --> $DIR/by_value.rs:21:5
12    |
13 LL | /     || {
14 LL | |
15 LL | |
16 LL | |         let p = t.0.0;
17 ...  |
18 LL | |
19 LL | |     };
20    | |_____^
21    |
22 note: Capturing t[(0, 0),Deref,(0, 0)] -> ImmBorrow
23   --> $DIR/by_value.rs:24:17
24    |
25 LL |         let p = t.0.0;
26    |                 ^^^^^
27 note: Capturing t[(0, 0)] -> ByValue
28   --> $DIR/by_value.rs:24:17
29    |
30 LL |         let p = t.0.0;
31    |                 ^^^^^
32 note: Capturing t[(1, 0)] -> ImmBorrow
33   --> $DIR/by_value.rs:28:29
34    |
35 LL |         println!("{} {:?}", t.1, p);
36    |                             ^^^
37
38 error: Min Capture analysis includes:
39   --> $DIR/by_value.rs:21:5
40    |
41 LL | /     || {
42 LL | |
43 LL | |
44 LL | |         let p = t.0.0;
45 ...  |
46 LL | |
47 LL | |     };
48    | |_____^
49    |
50 note: Min Capture t[(0, 0)] -> ByValue
51   --> $DIR/by_value.rs:24:17
52    |
53 LL |         let p = t.0.0;
54    |                 ^^^^^
55 note: Min Capture t[(1, 0)] -> ImmBorrow
56   --> $DIR/by_value.rs:28:29
57    |
58 LL |         println!("{} {:?}", t.1, p);
59    |                             ^^^
60
61 error: aborting due to 3 previous errors
62
63 For more information about this error, try `rustc --explain E0658`.