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
Fix float to float ToPrimitive implementation.

The mimimum (negative) value of a float is -Bounded::max_value(), not Bounded::min_value().
Make std::rt::io::extensions public

This works around #9779, but is probably the right thing to do anyways
since that's the module where all of the documentation for those traits
lives.
Forbid modifications of strings in the compiler

This disallows `str[0] = foo` along with `foo = &mut str[i]` to prevent strings
from being modified at runtime (except possibly through the `str` module)

Closes #8891
Implement io::native::file
Implement io::native::stdio
Implement io::native::process
Don't abort if the runtime is run twice.

This changes an `assert_once_ever!` assertion to just a plain old assertion
around an atomic boolean to ensure that one particular runtime doesn't attempt
to exit twice.

Closes #9739
auto merge of #9742 : alexcrichton/rust/issue-9739, r=brson

This changes an `assert_once_ever!` assertion to just a plain old assertion
around an atomic boolean to ensure that one particular runtime doesn't attempt
to exit twice.

Closes #9739
auto merge of #9750 : alexcrichton/rust/safer-strings, r=brson

This behavior was decided to get out-right forbidden by the compiler


Closes #8891
syntax: allow macros to expand to items with attributes.

Fixes #4471.
auto merge of #9774 : sebcrozet/rust/master, r=huonw

The minimum (negative) value of a float is `-Bounded::max_value()`, not `Bounded::min_value()`.
Otherwise the following has an incorrect behavior:

```rust
let a = -1.0f64;
let b: f32 = NumCast::from(a); // incorrectly returns None
```
auto merge of #9780 : sfackler/rust/extensions2, r=alexcrichton

This works around #9779, but is probably the right thing to do anyways
since that's the module where all of the documentation for those traits
lives.
auto merge of #9783 : huonw/rust/macro-items, r=bstrie

Fixes #4471.
Use the result of privacy for reachability

This fixes a bug in which the visibility rules were approximated by
reachability, but forgot to cover the case where a 'pub use' reexports a private
item. This fixes the commit by instead using the results of the privacy pass of
the compiler to create the initial working set of the reachability pass.

This may have the side effect of increasing the size of metadata, but it's
difficult to avoid for correctness purposes sadly.

Closes #9790
Implement rt::io::stdio

Additionally, this moves the prelude imports of print/println from std::io to
std::rt::io.

Closes #6846