rust/tests/ui/traits/const-traits/impl-with-default-fn-fail.rs

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

19 lines
256 B
Rust
Raw Normal View History

2024-06-25 09:50:01 +00:00
#![allow(incomplete_features)]
#![feature(const_trait_impl, effects)]
#[const_trait]
trait Tr {
fn req(&self);
2021-07-04 04:24:20 +00:00
fn default() {}
}
struct S;
2021-07-04 04:24:20 +00:00
impl const Tr for u16 {
fn default() {}
} //~^^ ERROR not all trait items implemented
2021-07-04 04:24:20 +00:00
fn main() {}