1 error: higher-ranked subtype error
2 --> $DIR/issue-57611-trait-alias.rs:28:9
7 error: higher-ranked subtype error
8 --> $DIR/issue-57611-trait-alias.rs:28:9
13 error[E0308]: mismatched types
14 --> $DIR/issue-57611-trait-alias.rs:20:16
16 LL | type Bar = impl Baz<Self, Self>;
17 | ^^^^^^^^^^^^^^^^^^^^ one type is more general than the other
19 = note: expected type `for<'r> Fn<(&'r X,)>`
20 found type `Fn<(&'static X,)>`
21 note: this closure does not fulfill the lifetime requirements
22 --> $DIR/issue-57611-trait-alias.rs:28:9
27 error: implementation of `FnOnce` is not general enough
28 --> $DIR/issue-57611-trait-alias.rs:20:16
30 LL | type Bar = impl Baz<Self, Self>;
31 | ^^^^^^^^^^^^^^^^^^^^ implementation of `FnOnce` is not general enough
33 = note: closure with signature `fn(&'static X) -> &'static X` must implement `FnOnce<(&'0 X,)>`, for any lifetime `'0`...
34 = note: ...but it actually implements `FnOnce<(&'static X,)>`
36 error: aborting due to 4 previous errors
38 For more information about this error, try `rustc --explain E0308`.