From b6d7ea2a9a7a7406bbad7144ca2891b5f6efb769 Mon Sep 17 00:00:00 2001 From: "Celina G. Val" Date: Wed, 12 Jun 2024 08:50:54 -0700 Subject: [PATCH] Remove redundant check --- library/core/src/intrinsics.rs | 6 ------ 1 file changed, 6 deletions(-) diff --git a/library/core/src/intrinsics.rs b/library/core/src/intrinsics.rs index 97c1e7a4fc2ba..1ab7ef9b5dc72 100644 --- a/library/core/src/intrinsics.rs +++ b/library/core/src/intrinsics.rs @@ -3178,17 +3178,11 @@ mod verify { pub fn check_swap() { let mut x = kani::any::(); let old_x = x; - let x_addr = (&x as *const T).addr(); - let mut y = kani::any::(); let old_y = y; - let y_addr = (&y as *const T).addr(); unsafe { typed_swap(&mut x, &mut y) }; - assert_eq!(y, old_x); assert_eq!(x, old_y); - assert_eq!(y_addr, (&y as *const T).addr()); - assert_eq!(x_addr, (&x as *const T).addr()); } }