rust/tests/ui/const-generics/issues/issue-71611.rs
2023-01-11 09:32:08 +00:00

12 lines
363 B
Rust

// revisions: full min
#![cfg_attr(full, feature(adt_const_params))]
#![cfg_attr(full, allow(incomplete_features))]
fn func<A, const F: fn(inner: A)>(outer: A) {
//~^ ERROR: using function pointers as const generic parameters is forbidden
//~| ERROR: the type of const parameters must not depend on other generic parameters
F(outer);
}
fn main() {}