error[E0658]: declaration of a nonstandard #[main] function may change over time, for now a top-level `fn main()` is required --> $DIR/feature-gate-main.rs:2:1 | LL | fn foo() {} | ^^^^^^^^^^^ | = note: for more information, see https://github.com/rust-lang/rust/issues/29634 = help: add #![feature(main)] to the crate attributes to enable error: aborting due to previous error For more information about this error, try `rustc --explain E0658`.