Rollup merge of #67543 - JohnTitor:regression-tests, r=Centril
Add regression tests for fixed ICEs Closes #61747 (fixed from 1.41.0-nightly (4007d4ef22019-12-01)) Closes #66205 (fixed from 1.41.0-nightly (4007d4ef22019-12-01)) Closes #66270 (fixed by #66246) Closes #67424 (fixed by #67160) Also picking a minor nit up from #67071 with101dd7bad9r? @Centril
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
// Regression test for #66270, fixed by #66246
|
||||
|
||||
struct Bug {
|
||||
incorrect_field: 0,
|
||||
//~^ ERROR expected type
|
||||
}
|
||||
|
||||
struct Empty {}
|
||||
|
||||
fn main() {
|
||||
let Bug {
|
||||
any_field: Empty {},
|
||||
} = Bug {};
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
error: expected type, found `0`
|
||||
--> $DIR/issue-66270-pat-struct-parser-recovery.rs:4:22
|
||||
|
|
||||
LL | incorrect_field: 0,
|
||||
| ^ expected type
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
Reference in New Issue
Block a user