rust/tests/ui/rfcs/rfc-2632-const-trait-impl/function-pointer-does-not-require-const.rs
2024-02-16 20:02:50 +00:00

16 lines
208 B
Rust

//@ check-pass
#![feature(const_trait_impl)]
#[const_trait]
pub trait Test {}
impl Test for () {}
pub const fn test<T: ~const Test>() {}
pub const fn min_by_i32() -> fn() {
test::<()>
}
fn main() {}