diff options
Diffstat (limited to 'tests/ui/pattern/pat-type-err-formal-param.rs')
-rw-r--r-- | tests/ui/pattern/pat-type-err-formal-param.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/ui/pattern/pat-type-err-formal-param.rs b/tests/ui/pattern/pat-type-err-formal-param.rs new file mode 100644 index 000000000..54336b349 --- /dev/null +++ b/tests/ui/pattern/pat-type-err-formal-param.rs @@ -0,0 +1,8 @@ +// Test the `.span_label(..)` to the type when there's a +// type error in a pattern due to a the formal parameter. + +fn main() {} + +struct Tuple(u8); + +fn foo(Tuple(_): String) {} //~ ERROR mismatched types |