chore: Fix typos in 'compiler' (batch 2)
This commit is contained in:
parent
78d5c04d9c
commit
00de006f22
34 changed files with 54 additions and 54 deletions
|
@ -288,7 +288,7 @@ impl IntRange {
|
|||
/// Best effort; will not know that e.g. `255u8..` is a singleton.
|
||||
pub fn is_singleton(&self) -> bool {
|
||||
// Since `lo` and `hi` can't be the same `Infinity` and `plus_one` never changes from finite
|
||||
// to infinite, this correctly only detects ranges that contain exacly one `Finite(x)`.
|
||||
// to infinite, this correctly only detects ranges that contain exactly one `Finite(x)`.
|
||||
self.lo.plus_one() == Some(self.hi)
|
||||
}
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ fn check(patterns: Vec<DeconstructedPat<Cx>>) -> Vec<WitnessPat<Cx>> {
|
|||
fn assert_exhaustive(patterns: Vec<DeconstructedPat<Cx>>) {
|
||||
let witnesses = check(patterns);
|
||||
if !witnesses.is_empty() {
|
||||
panic!("non-exaustive match: missing {witnesses:?}");
|
||||
panic!("non-exhaustive match: missing {witnesses:?}");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue