1 error[E0308]: mismatched types
2 --> $DIR/closure-no-fn-2.rs:16:27
4 LL | let bar: fn() -> u8 = || { b };
5 | ^^^^^^^^ expected fn pointer, found closure
7 = note: expected type `fn() -> u8`
8 found type `[closure@$DIR/closure-no-fn-2.rs:16:27: 16:35 b:_]`
10 error: aborting due to previous error
12 For more information about this error, try `rustc --explain E0308`.