fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error: constant expression depends on a generic parameter 2 --> $DIR/issue-62504.rs:18:25 3 | 4LL | ArrayHolder([0; Self::SIZE]) 5 | ^^^^^^^^^^ 6 | 7 = note: this may fail depending on what value the parameter takes 8 9error[E0308]: mismatched types 10 --> $DIR/issue-62504.rs:18:21 11 | 12LL | ArrayHolder([0; Self::SIZE]) 13 | ----------- ^^^^^^^^^^^^^^^ expected `X`, found `Self::SIZE` 14 | | 15 | arguments to this struct are incorrect 16 | 17 = note: expected array `[u32; X]` 18 found array `[u32; Self::SIZE]` 19note: tuple struct defined here 20 --> $DIR/issue-62504.rs:14:8 21 | 22LL | struct ArrayHolder<const X: usize>([u32; X]); 23 | ^^^^^^^^^^^ 24 25error: aborting due to 2 previous errors 26 27For more information about this error, try `rustc --explain E0308`.