fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error[E0308]: mismatched types 2 --> $DIR/len.rs:3:10 3 | 4LL | test(array.len()); 5 | ---- ^^^^^^^^^^^ expected `u32`, found `usize` 6 | | 7 | arguments to this function are incorrect 8 | 9note: function defined here 10 --> $DIR/len.rs:6:4 11 | 12LL | fn test(length: u32) { 13 | ^^^^ ----------- 14help: you can convert a `usize` to a `u32` and panic if the converted value doesn't fit 15 | 16LL | test(array.len().try_into().unwrap()); 17 | ++++++++++++++++++++ 18 19error: aborting due to previous error 20 21For more information about this error, try `rustc --explain E0308`.