rust/src/test/compile-fail/issue-4517.rs

7 lines
194 B
Rust
Raw Normal View History

2013-02-19 01:55:37 -06:00
fn bar(int_param: int) {}
fn main() {
let foo: [u8, ..4] = [1u8, ..4u8];
bar(foo); //~ ERROR mismatched types: expected `int` but found `[u8, .. 4]` (expected int but found vector)
2013-02-19 01:55:37 -06:00
}