#![feature(generic_const_exprs, const_generics_defaults)] #![allow(incomplete_features)] pub struct Foo; pub fn needs_evaluatable_bound() -> Foo { //~^ error: unconstrained generic constant loop {} } pub fn has_evaluatable_bound() -> Foo where [(); N1 + 1]: { loop {} } type FooAlias = [(); NP]; fn needs_evaluatable_bound_alias() -> FooAlias { //~^^ error: unconstrained generic constant todo!() } fn has_evaluatable_bound_alias() -> FooAlias where [(); N + 1]: { todo!() } fn main() {}