]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/array-size-in-generic-struct-param.stderr
14cf64eeb7ac69841461972e8e033910824b6869
[rust.git] / src / test / ui / const-generics / array-size-in-generic-struct-param.stderr
1 warning: the feature `const_generics` is incomplete and may not be safe to use and/or cause compiler crashes
2   --> $DIR/array-size-in-generic-struct-param.rs:1:12
3    |
4 LL | #![feature(const_generics)]
5    |            ^^^^^^^^^^^^^^
6    |
7    = note: `#[warn(incomplete_features)]` on by default
8    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
9
10 error: constant expression depends on a generic parameter
11   --> $DIR/array-size-in-generic-struct-param.rs:5:38
12    |
13 LL | struct ArithArrayLen<const N: usize>([u32; 0 + N]);
14    |                                      ^^^^^^^^^^^^
15    |
16    = note: this may fail depending on what value the parameter takes
17
18 error: constant expression depends on a generic parameter
19   --> $DIR/array-size-in-generic-struct-param.rs:14:5
20    |
21 LL |     arr: [u8; CFG.arr_size],
22    |     ^^^^^^^^^^^^^^^^^^^^^^^
23    |
24    = note: this may fail depending on what value the parameter takes
25
26 error: aborting due to 2 previous errors; 1 warning emitted
27