rust/tests/ui/rfcs/rfc-2632-const-trait-impl/inherent-impl.rs

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

14 lines
218 B
Rust
Raw Normal View History

2020-01-03 00:31:30 +00:00
#![feature(const_trait_impl)]
#![allow(bare_trait_objects)]
struct S;
trait T {}
2020-01-14 04:30:34 +00:00
impl const S {}
//~^ ERROR inherent impls cannot be `const`
2020-01-03 00:31:30 +00:00
impl const T {}
2020-01-14 04:30:34 +00:00
//~^ ERROR inherent impls cannot be `const`
2020-01-03 00:31:30 +00:00
fn main() {}