rust/tests/rustdoc/const-generics/const-generic-slice.rs
2023-01-11 09:32:08 +00:00

12 lines
239 B
Rust

#![crate_name = "foo"]
pub trait Array {
type Item;
}
// @has foo/trait.Array.html
// @has - '//*[@class="impl has-srclink"]' 'impl<T, const N: usize> Array for [T; N]'
impl<T, const N: usize> Array for [T; N] {
type Item = T;
}