Ensure matching arity of structs at the type level by encoding as a const generic on the struct.
Missing from this change is:
insurance that the arity isn't zero (blocked on some std::num::NonZero* work to make it work with const generics)
simplify basic usage a little by providing a default ARITY of 2 (blocked on rust issue #44580default values for const generic parameters are experimental)
The first change would be compatibility breaking, the second is not (pretty sure, anyway).
Ensure matching arity of structs at the type level by encoding as a const generic on the struct.
Missing from this change is:
default values for const generic parameters are experimental
)The first change would be compatibility breaking, the second is not (pretty sure, anyway).