about summary refs log tree commit diff
path: root/compiler/rustc_mir_transform/src
diff options
context:
space:
mode:
authorCamille Gillot <gillot.camille@gmail.com>2025-08-21 23:59:20 +0000
committerCamille Gillot <gillot.camille@gmail.com>2025-08-21 23:59:20 +0000
commite5bd01b533cfc85eb8a86d5f47d99e1c62d0e44d (patch)
treebf3a8be912b097e26ae5bbdef0275a4ea141fce7 /compiler/rustc_mir_transform/src
parent37e7f52876e490eaec1c55dad6702f02cbe181e5 (diff)
downloadrust-e5bd01b533cfc85eb8a86d5f47d99e1c62d0e44d.tar.gz
rust-e5bd01b533cfc85eb8a86d5f47d99e1c62d0e44d.zip
Correct comments.
Diffstat (limited to 'compiler/rustc_mir_transform/src')
-rw-r--r--compiler/rustc_mir_transform/src/gvn.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_mir_transform/src/gvn.rs b/compiler/rustc_mir_transform/src/gvn.rs
index ab9606fb99a..5a13394543b 100644
--- a/compiler/rustc_mir_transform/src/gvn.rs
+++ b/compiler/rustc_mir_transform/src/gvn.rs
@@ -447,7 +447,7 @@ impl<'body, 'tcx> VnState<'body, 'tcx> {
 
             Projection(base, elem) => {
                 let base = self.evaluated[base].as_ref()?;
-                // `Index` by constants should have been replaces by `ConstantIndex` by
+                // `Index` by constants should have been replaced by `ConstantIndex` by
                 // `simplify_place_projection`.
                 let elem = elem.try_map(|_| None, |()| ty.ty)?;
                 self.ecx.project(base, elem).discard_err()?
@@ -460,7 +460,7 @@ impl<'body, 'tcx> VnState<'body, 'tcx> {
                 let pointer = self.evaluated[local].as_ref()?;
                 let mut mplace = self.ecx.deref_pointer(pointer).discard_err()?;
                 for elem in place.projection.iter().skip(1) {
-                    // `Index` by constants should have been replaces by `ConstantIndex` by
+                    // `Index` by constants should have been replaced by `ConstantIndex` by
                     // `simplify_place_projection`.
                     let elem = elem.try_map(|_| None, |ty| ty)?;
                     mplace = self.ecx.project(&mplace, elem).discard_err()?;