Files
rust/src/libstd
bors a990920c6f auto merge of #13963 : kballard/rust/remove_owned_vec_from_iterator, r=pcwalton
With `~[T]` no longer growable, the `FromIterator` impl for `~[T]` doesn't make
much sense. Not only that, but nearly everywhere it is used is to convert from
a `Vec<T>` into a `~[T]`, for the sake of maintaining existing APIs. This turns
out to be a performance loss, as it means every API that returns `~[T]`, even a
supposedly non-copying one, is in fact doing extra allocations and memcpy's.
Even `&[T].to_owned()` is going through `Vec<T>` first.

Remove the `FromIterator` impl for `~[T]`, and adjust all the APIs that relied
on it to start using `Vec<T>` instead. This includes rewriting
`&[T].to_owned()` to be more efficient, among other performance wins.

Also add a new mechanism to go from `Vec<T>` -> `~[T]`, just in case anyone
truly needs that, using the new trait `FromVec`.

[breaking-change]
2014-05-08 21:01:42 -07:00
..
2014-05-07 11:03:12 -07:00
2014-05-07 08:16:14 -07:00
2014-05-08 12:06:22 -07:00
2014-05-08 12:08:01 -07:00
2014-05-08 12:06:22 -07:00
2014-05-08 12:08:01 -07:00
2014-04-08 00:03:11 -07:00
2014-05-07 08:14:56 -07:00
2014-05-08 12:06:22 -07:00
2014-05-07 23:43:39 -07:00
2014-05-07 11:03:12 -07:00
2014-05-08 12:06:21 -07:00
2014-05-02 23:00:58 -07:00
2014-05-07 11:03:12 -07:00
2014-04-04 09:31:21 -07:00
2014-05-08 12:08:01 -07:00
2014-05-08 12:06:21 -07:00