2023-03-18 21:17:44 -05:00
|
|
|
//@ incremental
|
|
|
|
#![crate_type = "lib"]
|
|
|
|
|
|
|
|
trait Q {
|
|
|
|
const ASSOC: usize;
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<const N: u64> Q for [u8; N] {
|
|
|
|
//~^ ERROR mismatched types
|
|
|
|
const ASSOC: usize = 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn test() -> [u8; <[u8; 13] as Q>::ASSOC] { todo!() }
|
2024-01-17 08:57:48 -06:00
|
|
|
//~^ ERROR: the constant `13` is not of type `u64`
|