]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/types-mismatch-const-args.min.stderr
Auto merge of #79342 - CDirkx:ipaddr-const, r=oli-obk
[rust.git] / src / test / ui / const-generics / types-mismatch-const-args.min.stderr
1 error[E0308]: mismatched types
2   --> $DIR/types-mismatch-const-args.rs:15:41
3    |
4 LL |     let _: A<'a, u32, {2u32}, {3u32}> = A::<'a, u32, {4u32}, {3u32}> { data: PhantomData };
5    |            --------------------------   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `2_u32`, found `4_u32`
6    |            |
7    |            expected due to this
8    |
9    = note: expected struct `A<'_, _, 2_u32, _>`
10               found struct `A<'_, _, 4_u32, _>`
11
12 error[E0308]: mismatched types
13   --> $DIR/types-mismatch-const-args.rs:17:41
14    |
15 LL |     let _: A<'a, u16, {2u32}, {3u32}> = A::<'b, u32, {2u32}, {3u32}> { data: PhantomData };
16    |            --------------------------   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `u16`, found `u32`
17    |            |
18    |            expected due to this
19    |
20    = note: expected struct `A<'a, u16, _, _>`
21               found struct `A<'b, u32, _, _>`
22
23 error: aborting due to 2 previous errors
24
25 For more information about this error, try `rustc --explain E0308`.