Rollup merge of #108244 - lukas-code:semicolon-recovery-span, r=cjgillot
Add test for semicolon recovery ICE closes https://github.com/rust-lang/rust/issues/108242
This commit is contained in:
commit
ced9cd19c8
2 changed files with 18 additions and 0 deletions
|
@ -0,0 +1,5 @@
|
|||
fn foo() {}
|
||||
fn main() {
|
||||
foo(;
|
||||
foo(;
|
||||
} //~ ERROR mismatched closing delimiter
|
|
@ -0,0 +1,13 @@
|
|||
error: mismatched closing delimiter: `}`
|
||||
--> $DIR/issue-108242-semicolon-recovery.rs:4:8
|
||||
|
|
||||
LL | fn main() {
|
||||
| - closing delimiter possibly meant for this
|
||||
LL | foo(;
|
||||
LL | foo(;
|
||||
| ^ unclosed delimiter
|
||||
LL | }
|
||||
| ^ mismatched closing delimiter
|
||||
|
||||
error: aborting due to previous error
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue