From 84edcb9869cc0b498fe22e5ba1296f45f9df206d Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Sun, 6 Aug 2023 22:50:05 +0200 Subject: [PATCH] fix typo: is_reserved --- src/tools/miri/src/borrow_tracker/tree_borrows/mod.rs | 2 +- src/tools/miri/src/borrow_tracker/tree_borrows/perms.rs | 2 +- 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 @@ fn tb_reborrow( // 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 @@ pub fn is_active(self) -> bool { matches!(self.inner, Active) } - pub fn is_resrved(self) -> bool { + pub fn is_reserved(self) -> bool { matches!(self.inner, Reserved { .. }) }