]> git.lizzy.rs Git - rust.git/blob - tests/ui/higher-lifetime-bounds.stderr
Rollup merge of #107740 - oli-obk:lock_tcx, r=petrochenkov
[rust.git] / tests / ui / higher-lifetime-bounds.stderr
1 error: lifetime bounds cannot be used in this context
2   --> $DIR/higher-lifetime-bounds.rs:8:22
3    |
4 LL |     f: for<'xa, 'xb: 'xa+'xa> fn(&'xa i32, &'xb i32) -> &'xa i32)
5    |                      ^^^ ^^^
6
7 error: lifetime bounds cannot be used in this context
8   --> $DIR/higher-lifetime-bounds.rs:16:34
9    |
10 LL | fn bar2<'a, 'b, F: for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32>(
11    |                                  ^^^
12
13 error: lifetime bounds cannot be used in this context
14   --> $DIR/higher-lifetime-bounds.rs:31:28
15    |
16 LL |     where F: for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32
17    |                            ^^^
18
19 error: lifetime bounds cannot be used in this context
20   --> $DIR/higher-lifetime-bounds.rs:43:25
21    |
22 LL |     where for<'xa, 'xb: 'xa> F: Fn(&'xa i32, &'xb i32) -> &'xa i32
23    |                         ^^^
24
25 error: lifetime bounds cannot be used in this context
26   --> $DIR/higher-lifetime-bounds.rs:51:28
27    |
28 LL | struct S1<F: for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32>(F);
29    |                            ^^^
30
31 error: lifetime bounds cannot be used in this context
32   --> $DIR/higher-lifetime-bounds.rs:53:40
33    |
34 LL | struct S2<F>(F) where F: for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32;
35    |                                        ^^^
36
37 error: lifetime bounds cannot be used in this context
38   --> $DIR/higher-lifetime-bounds.rs:55:37
39    |
40 LL | struct S3<F>(F) where for<'xa, 'xb: 'xa> F: Fn(&'xa i32, &'xb i32) -> &'xa i32;
41    |                                     ^^^
42
43 error: lifetime bounds cannot be used in this context
44   --> $DIR/higher-lifetime-bounds.rs:58:29
45    |
46 LL | struct S_fnty(for<'xa, 'xb: 'xa> fn(&'xa i32, &'xb i32) -> &'xa i32);
47    |                             ^^^
48
49 error: lifetime bounds cannot be used in this context
50   --> $DIR/higher-lifetime-bounds.rs:61:33
51    |
52 LL | type T1 = Box<dyn for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32>;
53    |                                 ^^^
54
55 error: lifetime bounds cannot be used in this context
56   --> $DIR/higher-lifetime-bounds.rs:65:34
57    |
58 LL |     let _ : Option<for<'xa, 'xb: 'xa> fn(&'xa i32, &'xb i32) -> &'xa i32> = None;
59    |                                  ^^^
60
61 error: lifetime bounds cannot be used in this context
62   --> $DIR/higher-lifetime-bounds.rs:67:42
63    |
64 LL |     let _ : Option<Box<dyn for<'xa, 'xb: 'xa> Fn(&'xa i32, &'xb i32) -> &'xa i32>> = None;
65    |                                          ^^^
66
67 error: aborting due to 11 previous errors
68