Skip to content

Commit d3fab38

Browse files
authored
Rollup merge of #140054 - c-git:patch-1, r=joboet
docs: fix typo change from inconstants to invariants
2 parents c113a3b + 6486538 commit d3fab38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/core/src/slice/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2814,7 +2814,7 @@ impl<T> [T] {
28142814
let half = size / 2;
28152815
let mid = base + half;
28162816

2817-
// SAFETY: the call is made safe by the following inconstants:
2817+
// SAFETY: the call is made safe by the following invariants:
28182818
// - `mid >= 0`: by definition
28192819
// - `mid < size`: `mid = size / 2 + size / 4 + size / 8 ...`
28202820
let cmp = f(unsafe { self.get_unchecked(mid) });

0 commit comments

Comments
 (0)