Rollup merge of #85712 - BlackHoleFox:fix-iter-typo, r=jyn514

Fix typo in core::array::IntoIter comment

Saw a small typo reading some internal comments and decided to just throw this up to fix it for future readers.
This commit is contained in:
Dylan DPC 2021-05-26 13:32:12 +02:00 committed by GitHub
commit 9ee87c7e00
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -139,7 +139,7 @@ unsafe fn __iterator_get_unchecked(&mut self, idx: usize) -> Self::Item
// SAFETY: Callers are only allowed to pass an index that is in bounds
// Additionally Self: TrustedRandomAccess is only implemented for T: Copy which means even
// multiple repeated reads of the same index would be safe and the
// values aree !Drop, thus won't suffer from double drops.
// values are !Drop, thus won't suffer from double drops.
unsafe { self.data.get_unchecked(self.alive.start + idx).assume_init_read() }
}
}