]> git.lizzy.rs Git - rust.git/blob - src/test/ui/array-not-vector.rs
Remove E0308 note when primary label has all info
[rust.git] / src / test / ui / array-not-vector.rs
1 fn main() {
2     let _x: i32 = [1, 2, 3];
3     //~^ ERROR mismatched types
4     //~| expected i32, found array
5
6     let x: &[i32] = &[1, 2, 3];
7     let _y: &i32 = x;
8     //~^ ERROR mismatched types
9     //~| expected reference `&i32`
10     //~| found reference `&[i32]`
11     //~| expected i32, found slice
12 }