about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2023-08-06 22:50:05 +0200
committerRalf Jung <post@ralfj.de>2023-08-06 22:50:05 +0200
commit84edcb9869cc0b498fe22e5ba1296f45f9df206d (patch)
tree6013f9abee8fedd44ddc90ac3f1c4fa1731ee0a4 /src
parentd1174a974e97017de75a33e7b878e13acdd3d5d5 (diff)
downloadrust-84edcb9869cc0b498fe22e5ba1296f45f9df206d.tar.gz
rust-84edcb9869cc0b498fe22e5ba1296f45f9df206d.zip
fix typo: is_reserved
Diffstat (limited to 'src')
-rw-r--r--src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs2
-rw-r--r--src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs b/src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs
index 0fbe66360b2..08b138c68ae 100644
--- a/src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs
+++ b/src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs
@@ -283,7 +283,7 @@ trait EvalContextPrivExt<'mir: 'ecx, 'tcx: 'mir, 'ecx>: crate::MiriInterpCxExt<'
                 // interleaving, but wether UB happens can depend on whether a write occurs in the
                 // future...
                 let is_write = new_perm.initial_state.is_active()
-                    || (new_perm.initial_state.is_resrved() && new_perm.protector.is_some());
+                    || (new_perm.initial_state.is_reserved() && new_perm.protector.is_some());
                 if is_write {
                     // Need to get mutable access to alloc_extra.
                     // (Cannot always do this as we can do read-only reborrowing on read-only allocations.)
diff --git a/src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs b/src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs
index b4a9a768e27..0ce29ac5437 100644
--- a/src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs
+++ b/src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs
@@ -152,7 +152,7 @@ impl Permission {
         matches!(self.inner, Active)
     }
 
-    pub fn is_resrved(self) -> bool {
+    pub fn is_reserved(self) -> bool {
         matches!(self.inner, Reserved { .. })
     }