Give better help for identifier patterns failing exhaustiveness check
This commit is contained in:
parent
3386757923
commit
765076faab
2 changed files with 11 additions and 4 deletions
|
|
@ -2,19 +2,19 @@ error[E0005]: refutable pattern in local binding: `_` not covered
|
|||
--> $DIR/const-pattern-irrefutable.rs:22:9
|
||||
|
|
||||
22 | let a = 4; //~ ERROR refutable pattern in local binding: `_` not covered
|
||||
| ^ pattern `_` not covered
|
||||
| ^ interpreted as a constant pattern, not new variable
|
||||
|
||||
error[E0005]: refutable pattern in local binding: `_` not covered
|
||||
--> $DIR/const-pattern-irrefutable.rs:23:9
|
||||
|
|
||||
23 | let c = 4; //~ ERROR refutable pattern in local binding: `_` not covered
|
||||
| ^ pattern `_` not covered
|
||||
| ^ interpreted as a constant pattern, not new variable
|
||||
|
||||
error[E0005]: refutable pattern in local binding: `_` not covered
|
||||
--> $DIR/const-pattern-irrefutable.rs:24:9
|
||||
|
|
||||
24 | let d = 4; //~ ERROR refutable pattern in local binding: `_` not covered
|
||||
| ^ pattern `_` not covered
|
||||
| ^ interpreted as a constant pattern, not new variable
|
||||
|
||||
error: aborting due to 3 previous errors
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue