diff options
author | Josh Mcguigan <[email protected]> | 2020-04-11 04:14:53 +0100 |
---|---|---|
committer | Josh Mcguigan <[email protected]> | 2020-04-11 04:14:53 +0100 |
commit | d1338354ca7afae7088f84756ed103ea94ce82f9 (patch) | |
tree | 750a1e7323380d9112ba0a64c9f8a5fff3cf3a13 /crates/ra_hir_ty/src/_match.rs | |
parent | beb755caa2b1d7265da7d3367af3b49039dfe00e (diff) |
fix match arm false positive
Diffstat (limited to 'crates/ra_hir_ty/src/_match.rs')
-rw-r--r-- | crates/ra_hir_ty/src/_match.rs | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/crates/ra_hir_ty/src/_match.rs b/crates/ra_hir_ty/src/_match.rs index 9e9a9d047..342a78b45 100644 --- a/crates/ra_hir_ty/src/_match.rs +++ b/crates/ra_hir_ty/src/_match.rs | |||
@@ -1315,8 +1315,9 @@ mod tests { | |||
1315 | } | 1315 | } |
1316 | "; | 1316 | "; |
1317 | 1317 | ||
1318 | // Match arms with the incorrect type are filtered out. | 1318 | // Match statements with arms that don't match the |
1319 | check_diagnostic(content); | 1319 | // expression pattern do not fire this diagnostic. |
1320 | check_no_diagnostic(content); | ||
1320 | } | 1321 | } |
1321 | 1322 | ||
1322 | #[test] | 1323 | #[test] |
@@ -1330,8 +1331,9 @@ mod tests { | |||
1330 | } | 1331 | } |
1331 | "; | 1332 | "; |
1332 | 1333 | ||
1333 | // Match arms with the incorrect type are filtered out. | 1334 | // Match statements with arms that don't match the |
1334 | check_diagnostic(content); | 1335 | // expression pattern do not fire this diagnostic. |
1336 | check_no_diagnostic(content); | ||
1335 | } | 1337 | } |
1336 | 1338 | ||
1337 | #[test] | 1339 | #[test] |
@@ -1344,8 +1346,9 @@ mod tests { | |||
1344 | } | 1346 | } |
1345 | "; | 1347 | "; |
1346 | 1348 | ||
1347 | // Match arms with the incorrect type are filtered out. | 1349 | // Match statements with arms that don't match the |
1348 | check_diagnostic(content); | 1350 | // expression pattern do not fire this diagnostic. |
1351 | check_no_diagnostic(content); | ||
1349 | } | 1352 | } |
1350 | 1353 | ||
1351 | #[test] | 1354 | #[test] |