2020-08-26 18:22:55 +08:00
|
|
|
// revisions: full min
|
|
|
|
|
#![cfg_attr(full, feature(const_generics))]
|
|
|
|
|
#![cfg_attr(full, allow(incomplete_features))]
|
|
|
|
|
#![cfg_attr(min, feature(min_const_generics))]
|
2020-06-27 20:34:16 +09:00
|
|
|
|
|
|
|
|
fn func<A, const F: fn(inner: A)>(outer: A) {
|
2020-08-26 18:22:55 +08:00
|
|
|
//[full]~^ ERROR: using function pointers as const generic parameters is forbidden
|
|
|
|
|
//[full]~| ERROR: the type of const parameters must not depend on other generic parameters
|
|
|
|
|
//[min]~^^^ ERROR: using function pointers as const generic parameters is forbidden
|
|
|
|
|
//[min]~| ERROR: the type of const parameters must not depend on other generic parameters
|
2020-06-27 20:34:16 +09:00
|
|
|
F(outer);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
fn main() {}
|