about summary refs log tree commit diff
path: root/tests/ui/async-await/async-closures/not-fn.stderr
blob: 4b9d2db9a253481a81391866aa249ce872913e6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
error: async closure does not implement `FnMut` because it captures state from its environment
  --> $DIR/not-fn.rs:9:14
   |
LL |     needs_fn(async || {
   |     -------- ^^^^^^^^
   |     |
   |     required by a bound introduced by this call
   |
note: required by a bound in `needs_fn`
  --> $DIR/not-fn.rs:6:28
   |
LL |     fn needs_fn<T>(_: impl FnMut() -> T) {}
   |                            ^^^^^^^^^^^^ required by this bound in `needs_fn`

error: aborting due to 1 previous error