Remove {As,Into,To}{Option,Either,Result} traits.

Expanded, that is:

- `AsOption`
- `IntoOption`
- `ToOption`
- `AsEither`
- `IntoEither`
- `ToEither`
- `AsResult`
- `IntoResult`
- `ToResult`

These were defined for each other but never *used* anywhere. They are
all trivial and so removal will have negligible effect upon anyone.
`Either` has fallen out of favour (and its implementation of these
traits of dubious semantics), `Option<T>` → `Result<T, ()>` was never
really useful and `Result<T, E>` → `Option<T>` should now be done with
`Result.ok()` (mirrored with `Result.err()` for even more usefulness).

In summary, there's really no point in any of these remaining.
Rename To{Str,Bytes}Consume traits to Into*.

That is:

- `ToStrConsume` → `IntoStr`;
- `ToBytesConsume` → `IntoBytes`.
Move logic for test output generation forward

By performing this logic very late in the build process, it ended up leading to
bugs like those found in #10973 where certain stages of the build process
expected a particular output format which didn't end up being the case. In order
to fix this, the build output generation is moved very early in the build
process to the absolute first thing in phase 2.

Closes #10973
std::vec: remove aliasing &mut [] and &[] from shift_opt.

Also, dramatically simplify it with some tasteful raw pointers, rather
than treating everything as a nail with `transmute`.
vec: avoid some unsafe code in MoveIterator's dtor
Remove obsolete mutability from ast::Ty
Detect stability attributes on methods.

If it's a trait method, this checks the stability attribute of the
method inside the trait definition. Otherwise, it checks the method
implementation itself.
std::vec::raw: convert init_elem to a method.
std::vec::raw: convert copy_memory to a method.
std::vec::bytes: remove the reference to overlapping src and dest in
docs for copy_memory.

&mut [u8] and &[u8] really shouldn't be overlapping at all (part of the
uniqueness/aliasing guarantee of &mut), so no point in encouraging it.
std::vec: convert .copy_memory to use copy_nonoverlapping_memory.

It is required that &mut[]s are disjoint from all other &(mut)[]s, so
this assumption is ok.
std::vec: make init_elem nicer by doing fewer moves.
provide an error at  at configure time if gcc, and g++ point to a mixture of clang and gcc. Fixes issue #10959

Signed-off-by: Carter Tazio Schonwald <carter.schonwald@gmail.com>
Rewrite std::comm

* Streams are now ~3x faster than before (fewer allocations and more optimized)
    * Based on a single-producer single-consumer lock-free queue that doesn't
      always have to allocate on every send.
    * Blocking via mutexes/cond vars outside the runtime
* Streams work in/out of the runtime seamlessly
* Select now works in/out of the runtime seamlessly
* Streams will now fail!() on send() if the other end has hung up
    * try_send() will not fail
* PortOne/ChanOne removed
* SharedPort removed
* MegaPipe removed
* Generic select removed (only one kind of port now)
* API redesign
    * try_recv == never block
    * recv_opt == block, don't fail
    * iter() == Iterator<T> for Port<T>
    * removed peek
    * Type::new
* Removed rt::comm
Fallout of rewriting std::comm
auto merge of #10964 : cartazio/rust/gcc-detector, r=alexcrichton

 @alexcrichton and others: heres a proof of concept patch for configure that (for now is OS X only) checks at the very end of the configure script if ``cc``, ``gcc``, and ``g++`` possibly point to the same compiler or not.

The way its currently done is i call ```cc  --version```, ``gcc --version`` and ``g++ --version`` and check if theres any matchings for the word ``clang``, ``gcc`` or ``g++``.  So it doesn't rule out miss matched gcc versions or the like, but thats a bit more implausible I think.
librustc: Implement a `Pod` kind for types that can be `memcpy`'d.

This will be used for the new `Cell`.
libstd: Implement the new `Cell`.
test: Add a test that POD types can be implicitly copied.
doc: Update the documentation to describe the `Pod` trait.