diff --git a/crates/ra_hir_ty/src/_match.rs b/crates/ra_hir_ty/src/_match.rs index 037db5cf8ab..9e9a9d04751 100644 --- a/crates/ra_hir_ty/src/_match.rs +++ b/crates/ra_hir_ty/src/_match.rs @@ -1334,6 +1334,20 @@ mod tests { check_diagnostic(content); } + #[test] + fn malformed_match_arm_tuple_missing_pattern() { + let content = r" + fn test_fn() { + match (0) { + () => (), + } + } + "; + + // Match arms with the incorrect type are filtered out. + check_diagnostic(content); + } + #[test] fn malformed_match_arm_tuple_enum_missing_pattern() { let content = r"