]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/generic_const_exprs/closures.stderr
0dfd804be41b48a0c44c0cae1a396c1d0c9b249f
[rust.git] / src / test / ui / const-generics / generic_const_exprs / closures.stderr
1 error: overly complex generic constant
2   --> $DIR/closures.rs:3:35
3    |
4 LL | fn test<const N: usize>() -> [u8; N + (|| 42)()] {}
5    |                                   ^^^^-------^^
6    |                                       |
7    |                                       dereferencing is not supported in generic constants
8    |
9    = help: consider moving this anonymous constant into a `const` function
10    = note: this operation may be supported in the future
11
12 error: aborting due to previous error
13