rust-lang/rust — pull request #18638 by aturon (2014-11-04 23:37:27+00:00)
Title: libcore: DST-ify AsSlice

This commit changes `AsSlice` to work on unsized types, and changes the
`impl` for `&[T]` to `[T]`. Aside from making the trait more general,
this also helps some ongoing work with method resolution changes.

This is a breaking change: code that uses generics bounded by `AsSlice`
will have to change. In particular, such code previously often took
arguments of type `V` where `V: AsSlice` by value. These should now
be taken by reference:

```rust
fn foo>(v: &V) { .. }
```

A few std lib functions have been changed accordingly.

[breaking-change]

r? @nikomatsakis
cc @japaric