about summary refs log tree commit diff
path: root/library/core
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2023-04-14 21:11:12 +0200
committerGitHub <noreply@github.com>2023-04-14 21:11:12 +0200
commitd1c480f986571c77e91f56f1139fa7bb60f9a28c (patch)
treeb4c2e67e4b007a4eeffc419c5b2c2532ce926e83 /library/core
parent5107c4c556fe9fb319f1330f6562882cf41d3097 (diff)
parenta0daf22b95ff1cd3f7ac55ea9370987535f3134d (diff)
downloadrust-d1c480f986571c77e91f56f1139fa7bb60f9a28c.tar.gz
rust-d1c480f986571c77e91f56f1139fa7bb60f9a28c.zip
Rollup merge of #110154 - DaniPopes:library-typos, r=JohnTitor
Fix typos in library

I ran [`typos -w library`](https://github.com/crate-ci/typos) to fix typos in the `library` directory.

Refs #110150
Diffstat (limited to 'library/core')
-rw-r--r--library/core/src/intrinsics/mir.rs2
-rw-r--r--library/core/src/slice/sort.rs2
-rw-r--r--library/core/src/str/pattern.rs2
3 files changed, 3 insertions, 3 deletions
diff --git a/library/core/src/intrinsics/mir.rs b/library/core/src/intrinsics/mir.rs
index d9d62eb759e..45498a54b25 100644
--- a/library/core/src/intrinsics/mir.rs
+++ b/library/core/src/intrinsics/mir.rs
@@ -247,7 +247,7 @@
 //!     - The exception is the last arm, which must be `_ => basic_block` and corresponds to the
 //!       otherwise branch.
 //!  - [`Call`] has an associated function as well. The third argument of this function is a normal
-//!    function call expresion, for example `my_other_function(a, 5)`.
+//!    function call expression, for example `my_other_function(a, 5)`.
 //!
 
 #![unstable(
diff --git a/library/core/src/slice/sort.rs b/library/core/src/slice/sort.rs
index 2333f60a888..07fd96f9295 100644
--- a/library/core/src/slice/sort.rs
+++ b/library/core/src/slice/sort.rs
@@ -1486,7 +1486,7 @@ where
 }
 
 /// Finds a streak of presorted elements starting at the beginning of the slice. Returns the first
-/// value that is not part of said streak, and a bool denoting wether the streak was reversed.
+/// value that is not part of said streak, and a bool denoting whether the streak was reversed.
 /// Streaks can be increasing or decreasing.
 fn find_streak<T, F>(v: &[T], is_less: &mut F) -> (usize, bool)
 where
diff --git a/library/core/src/str/pattern.rs b/library/core/src/str/pattern.rs
index 19da6d2fbec..e3a464a1c51 100644
--- a/library/core/src/str/pattern.rs
+++ b/library/core/src/str/pattern.rs
@@ -1891,7 +1891,7 @@ unsafe fn small_slice_eq(x: &[u8], y: &[u8]) -> bool {
 
     // SAFETY: Via the conditional above, we know that both `px` and `py`
     // have the same length, so `px < pxend` implies that `py < pyend`.
-    // Thus, derefencing both `px` and `py` in the loop below is safe.
+    // Thus, dereferencing both `px` and `py` in the loop below is safe.
     //
     // Moreover, we set `pxend` and `pyend` to be 4 bytes before the actual
     // end of `px` and `py`. Thus, the final dereference outside of the