aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/diagnostics.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-12-12 14:29:12 +0000
committerGitHub <[email protected]>2020-12-12 14:29:12 +0000
commit64a1c9810d5979cfd0fe6e7c385d9ca3caac2163 (patch)
tree79810e67885fbf9cc9317fd29d3fedba024ed8dc /crates/hir_ty/src/diagnostics.rs
parent70db57cc5959654004dc8bd044dc65b712e79553 (diff)
parentf7f4f366aca691ef848824e1738b014cb7028cf0 (diff)
Merge #6841
6841: Added "Remove this semicolon" test r=matklad a=ivan770 Closes https://github.com/rust-analyzer/rust-analyzer/pull/6769#discussion_r540150066 Co-authored-by: ivan770 <[email protected]>
Diffstat (limited to 'crates/hir_ty/src/diagnostics.rs')
-rw-r--r--crates/hir_ty/src/diagnostics.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/crates/hir_ty/src/diagnostics.rs b/crates/hir_ty/src/diagnostics.rs
index e59487e54..1c72f766e 100644
--- a/crates/hir_ty/src/diagnostics.rs
+++ b/crates/hir_ty/src/diagnostics.rs
@@ -624,4 +624,14 @@ fn foo() { break; }
624"#, 624"#,
625 ); 625 );
626 } 626 }
627
628 #[test]
629 fn missing_semicolon() {
630 check_diagnostics(
631 r#"
632 fn test() -> i32 { 123; }
633 //^^^ Remove this semicolon
634 "#,
635 );
636 }
627} 637}