rust/tests/ui/suggestions/issue-89333.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
550 B
Plaintext
Raw Normal View History

error[E0277]: the trait bound `for<'a> &'a _: Trait` is not satisfied
--> $DIR/issue-89333.rs:6:5
|
LL | test(&|| 0);
| ^^^^ the trait `for<'a> Trait` is not implemented for `&'a _`
|
note: required by a bound in `test`
--> $DIR/issue-89333.rs:11:55
|
LL | fn test<T>(arg: &impl Fn() -> T) where for<'a> &'a T: Trait {}
| ^^^^^ required by this bound in `test`
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.