2023-01-13 07:27:40 -06:00
|
|
|
//@ check-pass
|
2023-08-06 08:20:55 -05:00
|
|
|
#![feature(const_trait_impl, rustc_attrs, effects)]
|
2023-01-13 07:27:40 -06:00
|
|
|
|
|
|
|
#[const_trait]
|
|
|
|
trait Foo {
|
|
|
|
#[rustc_do_not_const_check]
|
|
|
|
fn into_iter(&self) { println!("FEAR ME!") }
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
impl const Foo for () {
|
|
|
|
fn into_iter(&self) {
|
|
|
|
// ^_^
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
const _: () = Foo::into_iter(&());
|
|
|
|
|
|
|
|
fn main() {}
|