Fixed type signature of uninhabited method.

Added unit test to prevent similar mistakes from happening again. The
previous method was wrong because it dereferenced a pointer to a void type to
match on the result. No self pointer was needed, and the correct method
signature took the self value by value.
core: Document some intrinsics
rustc: Change ty::get_impl_traits to return an option instead of a vec

Impls can implement either zero or one traits; this has been true
more or less since we removed classes. So I got rid of the comments
saying "we should support multiple traits" and changed the code to
make it clear that we don't. This is just cleanup, and doesn't break
any existing tests.
auto merge of #6543 : catamorphism/rust/traits-cleanup, r=nikomatsakis

r? @nikomatsakis Impls can implement either zero or one traits; this has been true
more or less since we removed classes. So I got rid of the comments
saying "we should support multiple traits" and changed the code to
make it clear that we don't. This is just cleanup, and doesn't break
any existing tests.
rustc: One less bad copy
rustc: Remove import that is, indeed, not necessary
auto merge of #6545 : catamorphism/rust/unused-import, r=catamorphism
Add reverse_part, replace each_permutation, add tests
Ensure reverse_part does not access outside given vector
Update to modern rust
iter: add fold, sum and product
fix warnings
auto merge of #6544 : thestinger/rust/new_iter, r=nikomatsakis
Remove each_permutation_ref
Implement sin_cos method for float, f64 and f32
Fix AtomicLoad builder code
Update to new for-loop protocol
auto merge of #6523 : cmr/rust/faster_each_permutation, r=luqmana

Closes #5127
auto merge of #6546 : cmr/rust/warning, r=thestinger
Re-implement lint with less emphasis on item ids

This way it's much easier to add lints throughout compilation correctly, and
functions on impls can alter the way lints are emitted.