☰
Debian Codegraph
@
15:15.3.rel1-2
15:15.3.rel1-1
/
/
gcc
/
testsuite
/
rust
/
compile
/
const_generics_5.rs
☽
☼
gcc/testsuite/rust/compile/const_generics_5.rs
code
plain
raw
1
// { dg-options "-w" }
2
struct Foo<const N: usize = { 14 }>;
3
4
const M: usize = 15;
5
type N = Foo<3>;
6
7
fn main() {
8
let _: Foo<15> = Foo;
9
let _: Foo<{ M }> = Foo;
10
let _: Foo<M> = Foo;
11
// let _: Foo<N> = Foo; this causes an ICE we need to do const generics
12
}