rust/tests/ui/rfcs/rfc-1937-termination-trait/termination-trait-impl-trait.rs

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

4 lines
157 B
Rust
Raw Normal View History

// Tests that an `impl Trait` that is not `impl Termination` will not work.
fn main() -> impl Copy { }
//~^ ERROR `main` has invalid return type `impl Copy`