Skip to contentSkip to conversation

docs: fix typo in rust/kernel/str.rs

PATCH Applied Jihed Chaibi 3 participants 3 messages May 17, 2025 – May 20, 2025 Rust

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 docs: fix typo in rust/kernel/str.rs

Fixing a minor grammar error ("then" to "than") in rust/kernel/str.rs

---
 rust/kernel/str.rs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
rust/kernel/str.rs +1 -1
index fb61ce81e..42f355f74 100644
@@ -752,7 +752,7 @@ pub(crate) unsafe fn from_ptrs(pos: *mut u8, end: *mut u8) -> Self {
     /// for the lifetime of the returned [`RawFormatter`].
     pub(crate) unsafe fn from_buffer(buf: *mut u8, len: usize) -> Self {
         let pos = buf as usize;
-        // INVARIANT: We ensure that `end` is never less then `buf`, and the safety requirements
+        // INVARIANT: We ensure that `end` is never less than `buf`, and the safety requirements
         // guarantees that the memory region is valid for writes.
         Self {
             pos,
Signature · 1 line
2.39.5
Applied
#2 lore raw
In reply to Jihed Chaibi
Quoted 4 lines · Jihed Chaibi

Fixing a minor grammar error ("then" to "than") in rust/kernel/str.rs

Applied to rust-next -- thanks everyone!

[ Reworded. - Miguel ]

When sending a fix, please try to find which commit introduces the mistake, and then add a Fixes: tag. That helps a lot when figuring out if something needs to be backported etc. :)

Fixes fffed679eeea ("rust: str: add `Formatter` type")

Cheers,
Miguel