Skip to content

Commit 1c1ae78

Browse files
authored
Fix spelling in SAFETY comment
"can not" should be "cannot", and add punctuation.
1 parent 3b0d481 commit 1c1ae78

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

library/core/src/num/nonzero.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ macro_rules! nonzero_leading_trailing_zeros {
213213
without modifying the original"]
214214
#[inline]
215215
pub const fn leading_zeros(self) -> u32 {
216-
// SAFETY: since `self` can not be zero it is safe to call ctlz_nonzero
216+
// SAFETY: since `self` cannot be zero, it is safe to call `ctlz_nonzero`.
217217
unsafe { intrinsics::ctlz_nonzero(self.0 as $Uint) as u32 }
218218
}
219219

@@ -237,7 +237,7 @@ macro_rules! nonzero_leading_trailing_zeros {
237237
without modifying the original"]
238238
#[inline]
239239
pub const fn trailing_zeros(self) -> u32 {
240-
// SAFETY: since `self` can not be zero it is safe to call cttz_nonzero
240+
// SAFETY: since `self` cannot be zero, it is safe to call `cttz_nonzero`.
241241
unsafe { intrinsics::cttz_nonzero(self.0 as $Uint) as u32 }
242242
}
243243

0 commit comments

Comments
 (0)