1
Fork 0

Revert "structural_match: non-structural-match ty closures"

Reverts #73353
This commit is contained in:
Santiago Pastorino 2021-07-14 19:00:48 -03:00
parent c34fb5167e
commit ba1e13fa66
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
2 changed files with 1 additions and 8 deletions

View file

@ -133,9 +133,6 @@ impl<'a, 'tcx> ConstToPat<'a, 'tcx> {
traits::NonStructuralMatchTy::Generator => {
"generators cannot be used in patterns".to_string()
}
traits::NonStructuralMatchTy::Closure => {
"closures cannot be used in patterns".to_string()
}
traits::NonStructuralMatchTy::Param => {
bug!("use of a constant whose type is a parameter inside a pattern")
}