1 // Test the `.span_label` to the type / scrutinee
2 // when there's a type error in checking a pattern.
5 // We want to point at the `Option<u8>`.
6 let Ok(0): Option<u8> = 42u8;
7 //~^ ERROR mismatched types
8 //~| ERROR mismatched types
10 // We want to point at the `Option<u8>`.
11 let Ok(0): Option<u8>;
12 //~^ ERROR mismatched types
14 // We want to point at the scrutinee.
15 let Ok(0) = 42u8; //~ ERROR mismatched types