]> git.proxmox.com Git - rustc.git/blob - src/test/ui/nll/closure-requirements/propagate-from-trait-match.stderr
New upstream version 1.30.0~beta.7+dfsg1
[rustc.git] / src / test / ui / nll / closure-requirements / propagate-from-trait-match.stderr
1 note: External requirements
2 --> $DIR/propagate-from-trait-match.rs:42:36
3 |
4 LL | establish_relationships(value, |value| {
5 | ____________________________________^
6 LL | | //~^ ERROR the parameter type `T` may not live long enough
7 LL | |
8 LL | | // This function call requires that
9 ... |
10 LL | | require(value);
11 LL | | });
12 | |_____^
13 |
14 = note: defining type: DefId(0/1:16 ~ propagate_from_trait_match[317d]::supply[0]::{{closure}}[0]) with closure substs [
15 '_#1r,
16 T,
17 i32,
18 extern "rust-call" fn((T,))
19 ]
20 = note: number of external vids: 2
21 = note: where T: '_#1r
22
23 note: No external requirements
24 --> $DIR/propagate-from-trait-match.rs:38:1
25 |
26 LL | / fn supply<'a, T>(value: T)
27 LL | | where
28 LL | | T: Trait<'a>,
29 LL | | {
30 ... |
31 LL | | });
32 LL | | }
33 | |_^
34 |
35 = note: defining type: DefId(0/0:6 ~ propagate_from_trait_match[317d]::supply[0]) with substs [
36 '_#1r,
37 T
38 ]
39
40 error[E0309]: the parameter type `T` may not live long enough
41 --> $DIR/propagate-from-trait-match.rs:42:36
42 |
43 LL | establish_relationships(value, |value| {
44 | ____________________________________^
45 LL | | //~^ ERROR the parameter type `T` may not live long enough
46 LL | |
47 LL | | // This function call requires that
48 ... |
49 LL | | require(value);
50 LL | | });
51 | |_____^
52 |
53 = help: consider adding an explicit lifetime bound `T: ReEarlyBound(0, 'a)`...
54
55 error: aborting due to previous error
56
57 For more information about this error, try `rustc --explain E0309`.