summaryrefslogtreecommitdiffstats
path: root/library/core/src/array
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
commitdc0db358abe19481e475e10c32149b53370f1a1c (patch)
treeab8ce99c4b255ce46f99ef402c27916055b899ee /library/core/src/array
parentReleasing progress-linux version 1.71.1+dfsg1-2~progress7.99u1. (diff)
downloadrustc-dc0db358abe19481e475e10c32149b53370f1a1c.tar.xz
rustc-dc0db358abe19481e475e10c32149b53370f1a1c.zip
Merging upstream version 1.72.1+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'library/core/src/array')
-rw-r--r--library/core/src/array/mod.rs23
1 files changed, 0 insertions, 23 deletions
diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs
index fec92320a..76b3589b9 100644
--- a/library/core/src/array/mod.rs
+++ b/library/core/src/array/mod.rs
@@ -538,29 +538,6 @@ impl<T, const N: usize> [T; N] {
drain_array_with(self, |iter| try_from_trusted_iterator(iter.map(f)))
}
- /// 'Zips up' two arrays into a single array of pairs.
- ///
- /// `zip()` returns a new array where every element is a tuple where the
- /// first element comes from the first array, and the second element comes
- /// from the second array. In other words, it zips two arrays together,
- /// into a single one.
- ///
- /// # Examples
- ///
- /// ```
- /// #![feature(array_zip)]
- /// let x = [1, 2, 3];
- /// let y = [4, 5, 6];
- /// let z = x.zip(y);
- /// assert_eq!(z, [(1, 4), (2, 5), (3, 6)]);
- /// ```
- #[unstable(feature = "array_zip", issue = "80094")]
- pub fn zip<U>(self, rhs: [U; N]) -> [(T, U); N] {
- drain_array_with(self, |lhs| {
- drain_array_with(rhs, |rhs| from_trusted_iterator(crate::iter::zip(lhs, rhs)))
- })
- }
-
/// Returns a slice containing the entire array. Equivalent to `&s[..]`.
#[stable(feature = "array_as_slice", since = "1.57.0")]
#[rustc_const_stable(feature = "array_as_slice", since = "1.57.0")]