]> git.lizzy.rs Git - rust.git/blob - src/test/ui/unboxed-closures/unboxed-closures-infer-argument-types-two-region-pointers.stderr
Sync rust-lang/portable-simd@5f49d4c8435a25d804b2f375e949cb25479f5be9
[rust.git] / src / test / ui / unboxed-closures / unboxed-closures-infer-argument-types-two-region-pointers.stderr
1 error[E0312]: lifetime of reference outlives lifetime of borrowed content...
2   --> $DIR/unboxed-closures-infer-argument-types-two-region-pointers.rs:17:15
3    |
4 LL |         x.set(y);
5    |               ^
6    |
7 note: ...the reference is valid for the anonymous lifetime #2 defined here...
8   --> $DIR/unboxed-closures-infer-argument-types-two-region-pointers.rs:16:14
9    |
10 LL |       doit(0, &|x, y| {
11    |  ______________^
12 LL | |         x.set(y);
13 LL | |     });
14    | |_____^
15 note: ...but the borrowed content is only valid for the anonymous lifetime #3 defined here
16   --> $DIR/unboxed-closures-infer-argument-types-two-region-pointers.rs:16:14
17    |
18 LL |       doit(0, &|x, y| {
19    |  ______________^
20 LL | |         x.set(y);
21 LL | |     });
22    | |_____^
23
24 error: aborting due to previous error
25
26 For more information about this error, try `rustc --explain E0312`.