]> git.lizzy.rs Git - rust.git/blob - tests/ui/type-alias-impl-trait/generic_nondefining_use.stderr
Rollup merge of #104965 - zacklukem:p-option-as_ref-docs, r=scottmcm
[rust.git] / tests / ui / type-alias-impl-trait / generic_nondefining_use.stderr
1 error: non-defining opaque type use in defining scope
2   --> $DIR/generic_nondefining_use.rs:17:5
3    |
4 LL |     5u32
5    |     ^^^^
6    |
7 note: used non-generic type `u32` for generic parameter
8   --> $DIR/generic_nondefining_use.rs:7:12
9    |
10 LL | type OneTy<T> = impl Debug;
11    |            ^
12
13 error: non-defining opaque type use in defining scope
14   --> $DIR/generic_nondefining_use.rs:22:5
15    |
16 LL | type OneLifetime<'a> = impl Debug;
17    |                  -- cannot use static lifetime; use a bound lifetime instead or remove the lifetime parameter from the opaque type
18 ...
19 LL |     6u32
20    |     ^^^^
21
22 error: non-defining opaque type use in defining scope
23   --> $DIR/generic_nondefining_use.rs:27:5
24    |
25 LL |     7u32
26    |     ^^^^
27    |
28 note: used non-generic constant `123` for generic parameter
29   --> $DIR/generic_nondefining_use.rs:11:15
30    |
31 LL | type OneConst<const X: usize> = impl Debug;
32    |               ^^^^^^^^^^^^^^
33
34 error: aborting due to 3 previous errors
35