When encountering a moved value of a type that isn't `Clone` because of unmet obligations, but where all the unmet predicates reference crate-local types, mention them and suggest cloning, as we do in other cases already:
```
error[E0507]: cannot move out of `foo`, a captured variable in an `Fn` closure
--> f111.rs:14:25
|
13 | fn do_stuff(foo: Option<Foo>) {
| --- captured outer variable
14 | require_fn_trait(|| async {
| -- ^^^^^ `foo` is moved here
| |
| captured by this `Fn` closure
15 | if foo.map_or(false, |f| f.foo()) {
| ---
| |
| variable moved due to use in coroutine
| move occurs because `foo` has type `Option<Foo>`, which does not implement the `Copy` trait
|
note: if `Foo` implemented `Clone`, you could clone the value
--> f111.rs:4:1
|
4 | struct Foo;
| ^^^^^^^^^^ consider implementing `Clone` for this type
...
15 | if foo.map_or(false, |f| f.foo()) {
| --- you could clone this value
```
|
||
|---|---|---|
| .. | ||
| auxiliary | ||
| use-mod | ||
| import_trait_associated_functions-2015.rs | ||
| import_trait_associated_functions.rs | ||
| import_trait_associated_item_bad.rs | ||
| import_trait_associated_item_bad.stderr | ||
| import_trait_associated_item_glob.rs | ||
| issue-18986.rs | ||
| issue-18986.stderr | ||
| issue-60976-extern-use-primitive-type.rs | ||
| unused-trait-with-method-err.rs | ||
| unused-trait-with-method-err.stderr | ||
| use-after-move-based-on-type.rs | ||
| use-after-move-based-on-type.stderr | ||
| use-after-move-implicity-coerced-object.rs | ||
| use-after-move-implicity-coerced-object.stderr | ||
| use-after-move-self-based-on-type.rs | ||
| use-after-move-self-based-on-type.stderr | ||
| use-after-move-self.rs | ||
| use-after-move-self.stderr | ||
| use-associated-const.rs | ||
| use-associated-const.stderr | ||
| use-crate-self.rs | ||
| use-crate-self.stderr | ||
| use-from-trait-xc.rs | ||
| use-from-trait-xc.stderr | ||
| use-from-trait.rs | ||
| use-from-trait.stderr | ||
| use-keyword.rs | ||
| use-keyword.stderr | ||
| use-meta-mismatch.rs | ||
| use-meta-mismatch.stderr | ||
| use-nested-groups-error.rs | ||
| use-nested-groups-error.stderr | ||
| use-nested-groups-unused-imports.rs | ||
| use-nested-groups-unused-imports.stderr | ||
| use-paths-as-items.rs | ||
| use-paths-as-items.stderr | ||
| use-self-type.rs | ||
| use-self-type.stderr | ||
| use-super-global-path.rs | ||
| use-super-global-path.stderr | ||
| use.rs | ||