Add get_opt to std::vec
std::iter: Introduce .by_ref() adaptor

Creates a wrapper around a mutable reference to the iterator.

This is useful to allow applying iterator adaptors while still
retaining ownership of the original iterator value.

Example::

   let mut xs = range(0, 10);
   // sum the first five values
   let partial_sum = xs.by_ref().take(5).fold(0, |a, b| a + b);
   assert!(partial_sum == 10);
   // xs.next() is now `5`
   assert!(xs.next() == Some(5));
std::rt::uv::net: Handle `read_start` error

cc #9605
std::rt: Add NotConnected to IoErrorKind
rt::io::net::tcp: Fix eof_twice tests on Win32

cc #8811
improve C ABI

I borrow some ideas from clang's ABIInfo.h and TargetInfo.cpp.
LLVMType is replaced with ArgType, which is similar to clang's ABIArgInfo,
and I also merge attrs of FnType into it.

Now ABI implementation doesn't need to insert hidden return pointer
to arg_tys of FnType. Instead it is handled in foreign.rs.

This change also fixes LLVM assertion failure when compiling MIPS target.
Remove named extern blocks from the AST

There's currently a fair amount of code which is being ignored on unnamed blocks
(which are the default now), and I opted to leave it commented out for now. I
intend on very soon revisiting on how we perform linking with extern crates in
an effort to support static linking.
Add tests and un-xfail a few issues

Closes #4545
Closes #5791
Closes #6470
Closes #8044
auto merge of #9517 : crabtw/rust/cabi, r=nikomatsakis

I borrow some ideas from clang's ABIInfo.h and TargetInfo.cpp.
LLVMType is replaced with ArgType, which is similar to clang's ABIArgInfo,
and I also merge attrs of FnType into it.

Now ABI implementation doesn't need to insert hidden return pointer
to arg_tys of FnType. Instead it is handled in foreign.rs.

This change also fixes LLVM assertion failure when compiling MIPS target.
auto merge of #9804 : alexcrichton/rust/always-anon-extern, r=brson

There's currently a fair amount of code which is being ignored on unnamed blocks
(which are the default now), and I opted to leave it commented out for now. I
intend on very soon revisiting on how we perform linking with extern crates in
an effort to support static linking.
auto merge of #9805 : alexcrichton/rust/needstest, r=brson

Closes #4545
Closes #5791
Closes #6470
Closes #8044
De-pub some private runtime components

This change was waiting for privacy to get sorted out, which should be true now
that #8215 has landed.

Closes #4427
extra::tempfile: replace mkdtemp with an RAII wrapper

this incidentally stops `make check` from leaving directories in `/tmp`
auto merge of #9802 : ben0x539/rust/mkdtemp-raii, r=alexcrichton

this incidentally stops `make check` from leaving directories in `/tmp` (Closes #9764)
auto merge of #9803 : alexcrichton/rust/less-pub2, r=brson

This change was waiting for privacy to get sorted out, which should be true now
that #8215 has landed.

Closes #4427
correct names for `#[no_send]`/`#[no_freeze]` tests
Remove support for older CrateMap versions
clean up the `Rc`/`RcMut` types and move to libstd
auto merge of #9794 : thestinger/rust/rc, r=alexcrichton

I've left out a way to construct from a `Send` type until #9509 is resolved. I am confident that this interface can remain backwards compatible though, assuming we name the `Pointer` trait method `borrow`.

When there is a way to convert from `Send` (`from_send`), a future RAII-based `Mut` type can be used with this to implemented a mutable reference-counted pointer. For now, I've left around the `RcMut` type but it may drastically change or be removed.
auto merge of #9809 : fhahn/rust/remove-old-cratemap-code, r=alexcrichton

This patch removes the code responsible for handling older CrateMap versions (as discussed during #9593). Only the new (safer) layout is supported now.