about summary refs log tree commit diff
path: root/library/coretests/tests
diff options
context:
space:
mode:
authorokaneco <47607823+okaneco@users.noreply.github.com>2025-08-05 16:37:04 -0400
committerokaneco <47607823+okaneco@users.noreply.github.com>2025-08-05 16:37:04 -0400
commiteee6f804a9e4d8a95e4c012a96dac39bb2cc94ad (patch)
tree488b54c9eff97feab39a991eb1405a34dd837e21 /library/coretests/tests
parent213d946a384b46989f6fd9c8ae9c547b4e354455 (diff)
downloadrust-eee6f804a9e4d8a95e4c012a96dac39bb2cc94ad.tar.gz
rust-eee6f804a9e4d8a95e4c012a96dac39bb2cc94ad.zip
Renamed `isolate_most_least_significant_one` functions
libs-api has agreed to rename these functions to
`isolate_highest_one`/`isolate_lowest_one`
Diffstat (limited to 'library/coretests/tests')
-rw-r--r--library/coretests/tests/nonzero.rs20
-rw-r--r--library/coretests/tests/num/int_macros.rs12
-rw-r--r--library/coretests/tests/num/uint_macros.rs12
3 files changed, 22 insertions, 22 deletions
diff --git a/library/coretests/tests/nonzero.rs b/library/coretests/tests/nonzero.rs
index 00232c9b706..60e1149f6e6 100644
--- a/library/coretests/tests/nonzero.rs
+++ b/library/coretests/tests/nonzero.rs
@@ -321,7 +321,7 @@ fn nonzero_trailing_zeros() {
 }
 
 #[test]
-fn test_nonzero_isolate_most_significant_one() {
+fn test_nonzero_isolate_highest_one() {
     // Signed most significant one
     macro_rules! nonzero_int_impl {
         ($($T:ty),+) => {
@@ -335,8 +335,8 @@ fn test_nonzero_isolate_most_significant_one() {
                     let mut i = 0;
                     while i < <$T>::BITS {
                         assert_eq!(
-                            NonZero::<$T>::new(BITS >> i).unwrap().isolate_most_significant_one(),
-                            NonZero::<$T>::new(MOST_SIG_ONE >> i).unwrap().isolate_most_significant_one()
+                            NonZero::<$T>::new(BITS >> i).unwrap().isolate_highest_one(),
+                            NonZero::<$T>::new(MOST_SIG_ONE >> i).unwrap().isolate_highest_one()
                         );
                         i += 1;
                     }
@@ -356,8 +356,8 @@ fn test_nonzero_isolate_most_significant_one() {
                     let mut i = 0;
                     while i < <$T>::BITS {
                         assert_eq!(
-                            NonZero::<$T>::new(BITS >> i).unwrap().isolate_most_significant_one(),
-                            NonZero::<$T>::new(MOST_SIG_ONE >> i).unwrap().isolate_most_significant_one(),
+                            NonZero::<$T>::new(BITS >> i).unwrap().isolate_highest_one(),
+                            NonZero::<$T>::new(MOST_SIG_ONE >> i).unwrap().isolate_highest_one(),
                         );
                         i += 1;
                     }
@@ -371,7 +371,7 @@ fn test_nonzero_isolate_most_significant_one() {
 }
 
 #[test]
-fn test_nonzero_isolate_least_significant_one() {
+fn test_nonzero_isolate_lowest_one() {
     // Signed least significant one
     macro_rules! nonzero_int_impl {
         ($($T:ty),+) => {
@@ -385,8 +385,8 @@ fn test_nonzero_isolate_least_significant_one() {
                     let mut i = 0;
                     while i < <$T>::BITS {
                         assert_eq!(
-                            NonZero::<$T>::new(BITS << i).unwrap().isolate_least_significant_one(),
-                            NonZero::<$T>::new(LEAST_SIG_ONE << i).unwrap().isolate_least_significant_one()
+                            NonZero::<$T>::new(BITS << i).unwrap().isolate_lowest_one(),
+                            NonZero::<$T>::new(LEAST_SIG_ONE << i).unwrap().isolate_lowest_one()
                         );
                         i += 1;
                     }
@@ -406,8 +406,8 @@ fn test_nonzero_isolate_least_significant_one() {
                     let mut i = 0;
                     while i < <$T>::BITS {
                         assert_eq!(
-                            NonZero::<$T>::new(BITS << i).unwrap().isolate_least_significant_one(),
-                            NonZero::<$T>::new(LEAST_SIG_ONE << i).unwrap().isolate_least_significant_one(),
+                            NonZero::<$T>::new(BITS << i).unwrap().isolate_lowest_one(),
+                            NonZero::<$T>::new(LEAST_SIG_ONE << i).unwrap().isolate_lowest_one(),
                         );
                         i += 1;
                     }
diff --git a/library/coretests/tests/num/int_macros.rs b/library/coretests/tests/num/int_macros.rs
index 41d399c1ad9..ca32fce861f 100644
--- a/library/coretests/tests/num/int_macros.rs
+++ b/library/coretests/tests/num/int_macros.rs
@@ -194,7 +194,7 @@ macro_rules! int_module {
         }
 
         #[test]
-        fn test_isolate_most_significant_one() {
+        fn test_isolate_highest_one() {
             const BITS: $T = -1;
             const MOST_SIG_ONE: $T = 1 << (<$T>::BITS - 1);
 
@@ -203,15 +203,15 @@ macro_rules! int_module {
             let mut i = 0;
             while i < <$T>::BITS {
                 assert_eq!(
-                    (BITS >> i).isolate_most_significant_one(),
-                    (MOST_SIG_ONE >> i).isolate_most_significant_one()
+                    (BITS >> i).isolate_highest_one(),
+                    (MOST_SIG_ONE >> i).isolate_highest_one()
                 );
                 i += 1;
             }
         }
 
         #[test]
-        fn test_isolate_least_significant_one() {
+        fn test_isolate_lowest_one() {
             const BITS: $T = -1;
             const LEAST_SIG_ONE: $T = 1;
 
@@ -220,8 +220,8 @@ macro_rules! int_module {
             let mut i = 0;
             while i < <$T>::BITS {
                 assert_eq!(
-                    (BITS << i).isolate_least_significant_one(),
-                    (LEAST_SIG_ONE << i).isolate_least_significant_one()
+                    (BITS << i).isolate_lowest_one(),
+                    (LEAST_SIG_ONE << i).isolate_lowest_one()
                 );
                 i += 1;
             }
diff --git a/library/coretests/tests/num/uint_macros.rs b/library/coretests/tests/num/uint_macros.rs
index 7e02027bdd6..8f389de70aa 100644
--- a/library/coretests/tests/num/uint_macros.rs
+++ b/library/coretests/tests/num/uint_macros.rs
@@ -151,7 +151,7 @@ macro_rules! uint_module {
         }
 
         #[test]
-        fn test_isolate_most_significant_one() {
+        fn test_isolate_highest_one() {
             const BITS: $T = <$T>::MAX;
             const MOST_SIG_ONE: $T = 1 << (<$T>::BITS - 1);
 
@@ -160,15 +160,15 @@ macro_rules! uint_module {
             let mut i = 0;
             while i < <$T>::BITS {
                 assert_eq!(
-                    (BITS >> i).isolate_most_significant_one(),
-                    (MOST_SIG_ONE >> i).isolate_most_significant_one(),
+                    (BITS >> i).isolate_highest_one(),
+                    (MOST_SIG_ONE >> i).isolate_highest_one(),
                 );
                 i += 1;
             }
         }
 
         #[test]
-        fn test_isolate_least_significant_one() {
+        fn test_isolate_lowest_one() {
             const BITS: $T = <$T>::MAX;
             const LEAST_SIG_ONE: $T = 1;
 
@@ -177,8 +177,8 @@ macro_rules! uint_module {
             let mut i = 0;
             while i < <$T>::BITS {
                 assert_eq!(
-                    (BITS << i).isolate_least_significant_one(),
-                    (LEAST_SIG_ONE << i).isolate_least_significant_one(),
+                    (BITS << i).isolate_lowest_one(),
+                    (LEAST_SIG_ONE << i).isolate_lowest_one(),
                 );
                 i += 1;
             }