You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
test3.rs:15:22: 15:23 error: Illegal lifetime 'r: only 'static is allowed here
test3.rs:15 fn bar<'r,A,IA:Base<'r,A>>(b: &'r Bar<A>, blk: &fn(&'r A)) {
^
error: aborting due to previous error
Seems like this should work, since without the lifetimes involved, fn bar<A,IA:Base<A>>(...) works fine - the earlier type declaration of A makes it possible to use A as a parameter in the type bound.
The text was updated successfully, but these errors were encountered:
Add unnecessary lazy evaluation lint
changelog: Add [`unnecessary_lazy_evaluations`] lint that checks for usages of `unwrap_or_else` and similar functions that can be simplified.
Closesrust-lang#5715
Seems like this should work, since without the lifetimes involved,
fn bar<A,IA:Base<A>>(...)
works fine - the earlier type declaration ofA
makes it possible to useA
as a parameter in the type bound.The text was updated successfully, but these errors were encountered: