1 error[E0277]: the size for values of type `(dyn Fn() -> u32 + 'static)` cannot be known at compilation time
2 --> $DIR/issue-24446.rs:2:17
4 LL | static foo: dyn Fn() -> u32 = || -> u32 {
5 | ^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
7 = help: the trait `Sized` is not implemented for `(dyn Fn() -> u32 + 'static)`
9 error[E0277]: `(dyn Fn() -> u32 + 'static)` cannot be shared between threads safely
10 --> $DIR/issue-24446.rs:2:17
12 LL | static foo: dyn Fn() -> u32 = || -> u32 {
13 | ^^^^^^^^^^^^^^^ `(dyn Fn() -> u32 + 'static)` cannot be shared between threads safely
15 = help: the trait `Sync` is not implemented for `(dyn Fn() -> u32 + 'static)`
16 = note: shared static variables must have a type that implements `Sync`
18 error: aborting due to 2 previous errors
20 For more information about this error, try `rustc --explain E0277`.