]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/const_evaluatable_checked/let-bindings.stderr
5749defb3e12c679227424fb7eef06d8bf66ad61
[rust.git] / src / test / ui / const-generics / const_evaluatable_checked / let-bindings.stderr
1 error: overly complex generic constant
2   --> $DIR/let-bindings.rs:6:68
3    |
4 LL | fn test<const N: usize>() -> [u8; { let x = N; N + 1 }] where [u8; { let x = N; N + 1 }]: Default {
5    |                                                                    ^^^^^^-^^^^^^^^^^^^^
6    |                                                                          |
7    |                                                                          unsupported statement
8    |
9    = help: consider moving this anonymous constant into a `const` function
10
11 error: overly complex generic constant
12   --> $DIR/let-bindings.rs:6:35
13    |
14 LL | fn test<const N: usize>() -> [u8; { let x = N; N + 1 }] where [u8; { let x = N; N + 1 }]: Default {
15    |                                   ^^^^^^-^^^^^^^^^^^^^
16    |                                         |
17    |                                         unsupported statement
18    |
19    = help: consider moving this anonymous constant into a `const` function
20
21 error: aborting due to 2 previous errors
22