rust/tests/ui/auto-traits/auto-trait-validation.fixed

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

15 lines
419 B
Rust
Raw Normal View History

2021-10-03 17:58:10 +02:00
#![feature(auto_traits)]
2024-02-07 10:42:01 +08:00
#![allow(dead_code)]
2021-10-03 17:58:10 +02:00
//@ run-rustfix
auto trait Generic {}
//~^ auto traits cannot have generic parameters [E0567]
auto trait Bound {}
//~^ auto traits cannot have super traits or lifetime bounds [E0568]
auto trait LifetimeBound {}
//~^ auto traits cannot have super traits or lifetime bounds [E0568]
auto trait MyTrait { }
//~^ auto traits cannot have associated items [E0380]
fn main() {}