]> git.lizzy.rs Git - rust.git/blob - tests/ui/type-alias-impl-trait/generic_nondefining_use.stderr
Auto merge of #107328 - matthiaskrgr:rollup-lfqwo0o, r=matthiaskrgr
[rust.git] / tests / ui / type-alias-impl-trait / generic_nondefining_use.stderr
1 error[E0792]: expected generic type parameter, found `u32`
2   --> $DIR/generic_nondefining_use.rs:16:5
3    |
4 LL | type OneTy<T> = impl Debug;
5    |            - this generic parameter must be used with a generic type parameter
6 ...
7 LL |     5u32
8    |     ^^^^
9
10 error[E0792]: expected generic lifetime parameter, found `'static`
11   --> $DIR/generic_nondefining_use.rs:21:5
12    |
13 LL | type OneLifetime<'a> = impl Debug;
14    |                  -- cannot use static lifetime; use a bound lifetime instead or remove the lifetime parameter from the opaque type
15 ...
16 LL |     6u32
17    |     ^^^^
18
19 error[E0792]: expected generic constant parameter, found `123`
20   --> $DIR/generic_nondefining_use.rs:26:5
21    |
22 LL | type OneConst<const X: usize> = impl Debug;
23    |               -------------- this generic parameter must be used with a generic constant parameter
24 ...
25 LL |     7u32
26    |     ^^^^
27
28 error: aborting due to 3 previous errors
29
30 For more information about this error, try `rustc --explain E0792`.