Auto merge of #90746 - nnethercote:opt-pattern-matching, r=Nadrieril
Optimize pattern matching These commits speed up the `match-stress-enum` benchmark, which is very artificial, but the changes are simple enough that it's probably worth doing. r? `@Nadrieril`
This commit is contained in:
commit
936238a92b
1 changed files with 1 additions and 1 deletions
|
@ -797,7 +797,7 @@ fn is_useful<'p, 'tcx>(
|
|||
return ret;
|
||||
}
|
||||
|
||||
assert!(rows.iter().all(|r| r.len() == v.len()));
|
||||
debug_assert!(rows.iter().all(|r| r.len() == v.len()));
|
||||
|
||||
let ty = v.head().ty();
|
||||
let is_non_exhaustive = cx.is_foreign_non_exhaustive_enum(ty);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue