2020-11-23 11:54:31 +08:00
|
|
|
#![feature(auto_traits)]
|
2024-02-07 10:42:01 +08:00
|
|
|
#![allow(dead_code)]
|
2017-10-16 02:03:03 +08:00
|
|
|
|
2021-10-03 23:58:10 +08:00
|
|
|
//@ run-rustfix
|
|
|
|
|
2017-10-16 02:03:03 +08:00
|
|
|
auto trait Generic<T> {}
|
2017-12-05 06:55:14 +08:00
|
|
|
//~^ auto traits cannot have generic parameters [E0567]
|
2017-10-16 02:03:03 +08:00
|
|
|
auto trait Bound : Copy {}
|
2021-10-03 23:58:10 +08:00
|
|
|
//~^ auto traits cannot have super traits or lifetime bounds [E0568]
|
|
|
|
auto trait LifetimeBound : 'static {}
|
|
|
|
//~^ auto traits cannot have super traits or lifetime bounds [E0568]
|
2017-10-16 02:03:03 +08:00
|
|
|
auto trait MyTrait { fn foo() {} }
|
2021-10-03 23:58:10 +08:00
|
|
|
//~^ auto traits cannot have associated items [E0380]
|
2017-10-16 02:03:03 +08:00
|
|
|
fn main() {}
|