summaryrefslogtreecommitdiffstats
path: root/tests/ui/associated-types/associated-types-eq-hr.stderr
blob: 6cff403b318c193cd0e55e213debb9b6c772a1db (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
42
43
44
45
46
47
error[E0271]: type mismatch resolving `for<'x> <UintStruct as TheTrait<&'x isize>>::A == &'x isize`
  --> $DIR/associated-types-eq-hr.rs:87:11
   |
LL |     foo::<UintStruct>();
   |           ^^^^^^^^^^ type mismatch resolving `for<'x> <UintStruct as TheTrait<&'x isize>>::A == &'x isize`
   |
note: expected this to be `&isize`
  --> $DIR/associated-types-eq-hr.rs:26:14
   |
LL |     type A = &'a usize;
   |              ^^^^^^^^^
   = note: expected reference `&isize`
              found reference `&usize`
note: required by a bound in `foo`
  --> $DIR/associated-types-eq-hr.rs:45:36
   |
LL | fn foo<T>()
   |    --- required by a bound in this
LL | where
LL |     T: for<'x> TheTrait<&'x isize, A = &'x isize>,
   |                                    ^^^^^^^^^^^^^ required by this bound in `foo`

error[E0271]: type mismatch resolving `for<'x> <IntStruct as TheTrait<&'x isize>>::A == &'x usize`
  --> $DIR/associated-types-eq-hr.rs:91:11
   |
LL |     bar::<IntStruct>();
   |           ^^^^^^^^^ type mismatch resolving `for<'x> <IntStruct as TheTrait<&'x isize>>::A == &'x usize`
   |
note: expected this to be `&usize`
  --> $DIR/associated-types-eq-hr.rs:14:14
   |
LL |     type A = &'a isize;
   |              ^^^^^^^^^
   = note: expected reference `&usize`
              found reference `&isize`
note: required by a bound in `bar`
  --> $DIR/associated-types-eq-hr.rs:52:36
   |
LL | fn bar<T>()
   |    --- required by a bound in this
LL | where
LL |     T: for<'x> TheTrait<&'x isize, A = &'x usize>,
   |                                    ^^^^^^^^^^^^^ required by this bound in `bar`

error: aborting due to 2 previous errors

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