mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 16:24:46 +00:00
14 lines
242 B
Rust
14 lines
242 B
Rust
//@ compile-flags: -Znext-solver
|
|
#![feature(const_trait_impl)]
|
|
|
|
#[const_trait] trait Foo {
|
|
fn foo();
|
|
}
|
|
|
|
const fn foo<T: ~const Foo>() {
|
|
const { T::foo() }
|
|
//~^ ERROR the trait bound `T: const Foo` is not satisfied
|
|
}
|
|
|
|
fn main() {}
|