2 trait T<const A: usize> {
3 fn l<const N: bool>() -> usize;
4 fn r<const N: bool>() -> bool;
9 impl<const N: usize> T<N> for S {
10 fn l<const M: bool>() -> usize { N }
11 fn r<const M: bool>() -> bool { M }
15 assert_eq!(<S as T<123>>::l::<true>(), 123);
16 assert!(<S as T<123>>::r::<true>());