mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-30 14:01:51 +00:00
15 lines
215 B
Rust
15 lines
215 B
Rust
//@ known-bug: #118320
|
|
//@ edition:2021
|
|
#![feature(const_trait_impl, effects, const_closures)]
|
|
|
|
#[const_trait]
|
|
trait Bar {
|
|
fn foo(&self);
|
|
}
|
|
|
|
impl Bar for () {}
|
|
|
|
const FOO: () = {
|
|
(const || (()).foo())();
|
|
};
|