summaryrefslogtreecommitdiffstats
path: root/tests/ui/parser/issues/issue-87197-missing-semicolon.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/parser/issues/issue-87197-missing-semicolon.rs')
-rw-r--r--tests/ui/parser/issues/issue-87197-missing-semicolon.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/ui/parser/issues/issue-87197-missing-semicolon.rs b/tests/ui/parser/issues/issue-87197-missing-semicolon.rs
new file mode 100644
index 000000000..db0edf452
--- /dev/null
+++ b/tests/ui/parser/issues/issue-87197-missing-semicolon.rs
@@ -0,0 +1,10 @@
+// run-rustfix
+// Parser should know when a semicolon is missing.
+// https://github.com/rust-lang/rust/issues/87197
+
+fn main() {
+ let x = 100 //~ ERROR: expected `;`
+ println!("{}", x) //~ ERROR: expected `;`
+ let y = 200 //~ ERROR: expected `;`
+ println!("{}", y);
+}