rust/tests/ui/proc-macro/issue-59191-replace-root-with-fn.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
418 B
Rust
Raw Normal View History

2020-02-02 02:07:26 +00:00
// Test that using a macro to replace the entire crate tree with a non-'mod' item errors out nicely.
// `issue_59191::no_main` replaces whatever's passed in with `fn main() {}`.
//@ edition:2018
//@ proc-macro: issue-59191.rs
//@ needs-unwind (affects error output)
//@ error-pattern: error: `#[panic_handler]` function required
2020-02-02 02:07:26 +00:00
#![feature(custom_inner_attributes)]
#![issue_59191::no_main]
#![issue_59191::no_main]