summary refs log tree commit diff
path: root/src/test/ui/variance/variance-covariant-self-trait-match.stderr
blob: a25d1044d42565b80019b18b9b1908cee387e13b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
error[E0308]: mismatched types
  --> $DIR/variance-covariant-self-trait-match.rs:14:5
   |
LL |     impls_get::<&'min G>();
   |     ^^^^^^^^^^^^^^^^^^^^ lifetime mismatch
   |
   = note: expected type `Get`
              found type `Get`
note: the lifetime `'min` as defined on the function body at 10:21...
  --> $DIR/variance-covariant-self-trait-match.rs:10:21
   |
LL | fn get_min_from_max<'min, 'max, G>()
   |                     ^^^^
note: ...does not necessarily outlive the lifetime `'max` as defined on the function body at 10:27
  --> $DIR/variance-covariant-self-trait-match.rs:10:27
   |
LL | fn get_min_from_max<'min, 'max, G>()
   |                           ^^^^

error[E0308]: mismatched types
  --> $DIR/variance-covariant-self-trait-match.rs:20:5
   |
LL |     impls_get::<&'max G>();
   |     ^^^^^^^^^^^^^^^^^^^^ lifetime mismatch
   |
   = note: expected type `Get`
              found type `Get`
note: the lifetime `'min` as defined on the function body at 17:21...
  --> $DIR/variance-covariant-self-trait-match.rs:17:21
   |
LL | fn get_max_from_min<'min, 'max, G>()
   |                     ^^^^
note: ...does not necessarily outlive the lifetime `'max` as defined on the function body at 17:27
  --> $DIR/variance-covariant-self-trait-match.rs:17:27
   |
LL | fn get_max_from_min<'min, 'max, G>()
   |                           ^^^^

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0308`.