]> git.lizzy.rs Git - rust.git/blob - src/test/ui/polymorphization/generators.stderr
Rollup merge of #97917 - AronParker:master, r=ChrisDenton
[rust.git] / src / test / ui / polymorphization / generators.stderr
1 warning: the feature `generic_const_exprs` is incomplete and may not be safe to use and/or cause compiler crashes
2   --> $DIR/generators.rs:3:12
3    |
4 LL | #![feature(generic_const_exprs, generators, generator_trait, rustc_attrs)]
5    |            ^^^^^^^^^^^^^^^^^^^
6    |
7    = note: `#[warn(incomplete_features)]` on by default
8    = note: see issue #76560 <https://github.com/rust-lang/rust/issues/76560> for more information
9
10 error: item has unused generic parameters
11   --> $DIR/generators.rs:35:5
12    |
13 LL |   pub fn unused_type<T>() -> impl Generator<(), Yield = u32, Return = u32> + Unpin {
14    |                      - generic parameter `T` is unused
15 LL | /     || {
16 LL | |
17 LL | |         yield 1;
18 LL | |         2
19 LL | |     }
20    | |_____^
21
22 note: the above error was encountered while instantiating `fn finish::<[generator@$DIR/generators.rs:35:5: 39:6], u32, u32>`
23   --> $DIR/generators.rs:86:5
24    |
25 LL |     finish(unused_type::<u32>());
26    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
27
28 error: item has unused generic parameters
29   --> $DIR/generators.rs:60:5
30    |
31 LL |   pub fn unused_const<const T: u32>() -> impl Generator<(), Yield = u32, Return = u32> + Unpin {
32    |                       ------------ generic parameter `T` is unused
33 LL | /     || {
34 LL | |
35 LL | |         yield 1;
36 LL | |         2
37 LL | |     }
38    | |_____^
39
40 note: the above error was encountered while instantiating `fn finish::<[generator@$DIR/generators.rs:60:5: 64:6], u32, u32>`
41   --> $DIR/generators.rs:89:5
42    |
43 LL |     finish(unused_const::<1u32>());
44    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
45
46 error: aborting due to 2 previous errors; 1 warning emitted
47