summary refs log tree commit diff
path: root/src/test/ui/const-generics/generic_const_exprs/closures.stderr
blob: 18010413b9394528e0ef615a33b48fa5cfb2b1e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
error: overly complex generic constant
  --> $DIR/closures.rs:3:35
   |
LL | fn test<const N: usize>() -> [u8; N + (|| 42)()] {}
   |                                   ^^^^-------^^
   |                                       |
   |                                       borrowing is not supported in generic constants
   |
   = help: consider moving this anonymous constant into a `const` function
   = note: this operation may be supported in the future

error: aborting due to previous error