From 1ca8b69e1cddb0f3c601ee508519fedff227d9db Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Tue, 21 Jun 2022 16:38:12 -0700 Subject: [PATCH] remove use of &Alloc in btree tests --- library/alloc/src/collections/btree/node/tests.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/library/alloc/src/collections/btree/node/tests.rs b/library/alloc/src/collections/btree/node/tests.rs index c8634e6c06fe3..aadb0dc9c40d9 100644 --- a/library/alloc/src/collections/btree/node/tests.rs +++ b/library/alloc/src/collections/btree/node/tests.rs @@ -68,10 +68,10 @@ fn test_splitpoint() { #[test] fn test_partial_eq() { - let mut root1 = NodeRef::new_leaf(&Global); + let mut root1 = NodeRef::new_leaf(Global); root1.borrow_mut().push(1, ()); - let mut root1 = NodeRef::new_internal(root1.forget_type(), &Global).forget_type(); - let root2 = Root::new(&Global); + let mut root1 = NodeRef::new_internal(root1.forget_type(), Global).forget_type(); + let root2 = Root::new(Global); root1.reborrow().assert_back_pointers(); root2.reborrow().assert_back_pointers(); @@ -87,9 +87,9 @@ fn test_partial_eq() { assert!(top_edge_1 == top_edge_1); assert!(top_edge_1 != top_edge_2); - root1.pop_internal_level(&Global); - unsafe { root1.into_dying().deallocate_and_ascend(&Global) }; - unsafe { root2.into_dying().deallocate_and_ascend(&Global) }; + root1.pop_internal_level(Global); + unsafe { root1.into_dying().deallocate_and_ascend(Global) }; + unsafe { root2.into_dying().deallocate_and_ascend(Global) }; } #[test]