2020-01-02 18:31:30 -06:00
|
|
|
// revisions: stock gated
|
|
|
|
// gate-test-const_trait_impl
|
|
|
|
|
|
|
|
#![cfg_attr(gated, feature(const_trait_impl))]
|
2020-02-04 16:03:37 -06:00
|
|
|
#![feature(rustc_attrs)]
|
2020-01-02 18:31:30 -06:00
|
|
|
|
|
|
|
struct S;
|
2022-08-28 01:27:31 -05:00
|
|
|
#[const_trait] //[stock]~ ERROR `const_trait` is a temporary placeholder
|
2020-01-02 18:31:30 -06:00
|
|
|
trait T {}
|
|
|
|
impl const T for S {}
|
|
|
|
//[stock]~^ ERROR const trait impls are experimental
|
|
|
|
|
2020-02-04 16:03:37 -06:00
|
|
|
#[rustc_error]
|
|
|
|
fn main() {} //[gated]~ ERROR fatal error triggered by #[rustc_error]
|