style: Use an ArcSlice as the computed value representation of inherited list properties.

This adds a bit of complexity, which I think will pay off in the end. Removals
incoming.

Differential Revision: https://phabricator.services.mozilla.com/D30544
This commit is contained in:
Emilio Cobos Álvarez 2019-05-16 23:03:27 +00:00
parent 5e4fdf647d
commit 2bc4c42d45
4 changed files with 135 additions and 28 deletions

View file

@ -93,7 +93,7 @@ impl<T: Sized> OwnedSlice<T> {
/// Iterate over all the elements in the slice taking ownership of them.
#[inline]
pub fn into_iter(self) -> impl Iterator<Item = T> {
pub fn into_iter(self) -> impl Iterator<Item = T> + ExactSizeIterator {
self.into_vec().into_iter()
}