about summary refs log tree commit diff
path: root/tests/ui/impl-trait/precise-capturing/forgot-to-capture-const.stderr
blob: e8fab0a8ad6c93a34e202226c3fa9f935eabea85 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
error: `impl Trait` must mention all const parameters in scope in `use<...>`
  --> $DIR/forgot-to-capture-const.rs:1:34
   |
LL | fn constant<const C: usize>() -> impl Sized + use<> {}
   |             --------------       ^^^^^^^^^^^^^^^^^^
   |             |
   |             const parameter is implicitly captured by this `impl Trait`
   |
   = note: currently, all const parameters are required to be mentioned in the precise captures list

error: aborting due to 1 previous error