Files
rust/tests/ui/traits/const-traits/ice-113375-index-out-of-bounds-generics.rs

19 lines
356 B
Rust
Raw Normal View History

//@ check-pass
2024-06-30 17:08:45 +00:00
//@ compile-flags: -Znext-solver
2023-11-02 16:15:33 +01:00
// effects ice https://github.com/rust-lang/rust/issues/113375 index out of bounds
#![allow(incomplete_features, unused)]
2024-10-30 18:03:44 +00:00
#![feature(adt_const_params)]
2023-11-02 16:15:33 +01:00
struct Bar<T>(T);
impl<T> Bar<T> {
const fn value() -> usize {
42
}
}
struct Foo<const N: [u8; Bar::<u32>::value()]>;
pub fn main() {}