fork/rust
git clone https://git.julia.blue/fork/rust
73528e339aa
1.40.0
1error[E0379]: trait fns cannot be declared const 2 --> $DIR/issue-54954.rs:7:5 3 | 4LL | const fn const_val<T: Sized>() -> usize { 5 | ^^^^^ trait fns cannot be const 6 7error[E0283]: type annotations needed: cannot resolve `_: Tt` 8 --> $DIR/issue-54954.rs:3:24 9 | 10LL | const ARR_LEN: usize = Tt::const_val::<[i8; 123]>(); 11 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ 12... 13LL | const fn const_val<T: Sized>() -> usize { 14 | --------- - required by this bound in `Tt::const_val` 15 16error[E0080]: evaluation of constant value failed 17 --> $DIR/issue-54954.rs:13:15 18 | 19LL | fn f(z: [f32; ARR_LEN]) -> [f32; ARR_LEN] { 20 | ^^^^^^^ referenced constant has errors 21 22error[E0080]: evaluation of constant value failed 23 --> $DIR/issue-54954.rs:13:34 24 | 25LL | fn f(z: [f32; ARR_LEN]) -> [f32; ARR_LEN] { 26 | ^^^^^^^ referenced constant has errors 27 28error: aborting due to 4 previous errors 29 30Some errors have detailed explanations: E0080, E0283, E0379. 31For more information about an error, try `rustc --explain E0080`.