Merge remote-tracking branch 'upstream/io' into io

Conflicts:
	src/libstd/rt/uvio.rs
renamed finalize to drop in Drop impl for UvUdpSocket
changed .each() to .iter().advance()
auto merge of #7608 : glinscott/rust/json_perf, r=pcwalton

Avoids the overhead of read_char for every character.

Benchmark reading example.json 10 times from
https://code.google.com/p/rapidjson/wiki/Performance

Before: 2.55s
After:  0.16s

Regression testing is already done by isrustfastyet.
std::rt: Add a hack to allocate different test port ranges to different bots
Merge remote-tracking branch 'anasazi/io'

Conflicts:
	src/libstd/rt/test.rs
auto merge of #7612 : thestinger/rust/utf8, r=huonw
Merge remote-tracking branch 'mozilla/master'

Conflicts:
	src/libextra/test.rs
	src/libstd/rt/global_heap.rs
	src/libstd/unstable/lang.rs
	src/libstd/vec.rs
Tidy
std: Add a yield implementation for newsched
auto merge of #7262 : nikomatsakis/rust/ref-bindings-in-irrefut-patterns, r=catamorphism

Correct treatment of irrefutable patterns. The old code was wrong in many, many ways. `ref` bindings didn't work, it sometimes copied when it should have moved, the borrow checker didn't even look at such patterns at all, we weren't consistent about preventing values with destructors from being pulled apart, etc.

Fixes #3224.
Fixes #3225.
Fixes #3255.
Fixes #6225.
Fixes #6386.

r? @catamorphism
auto merge of #7578 : alexcrichton/rust/overflow, r=thestinger

This should never cause a segfault, but rather fail somehow. Possibly a condition could be used here, but for now there's not much else to do.
auto merge of #7614 : MarkJr94/rust/smallintmap_enum, r=huonw

Added external iterators as well as tests to SmallIntMap and SmallIntSet. Fixes #7366
auto merge of #7641 : lucab/rust/lucab/po4a, r=catamorphism

As per https://mail.mozilla.org/pipermail/rust-dev/2013-July/004685.html 

This is the initial machinery to setup the l10n infrastructure for markdown documentation.
A new "docs-l10n" target will take care of generating, updating and then building .pot and .po files, and later on the final .md.

This commit includes the .pot for all current .md docs; they can be feed directly to Mozilla Verbatim if wanted.
Please note that po4a only provides the orig.md -> .pot -> l10n.po -> l10n.md flow. The l10n.md -> l10n.html generation is not currently built in the makefile, as no language has been enabled.
Fix #3225: Incorporate feedback from Graydon.

Namely, switched in many places to using GNU make provided functions
for directory listing and text processing, rather than spawning a
shell process to do that work.

In the process of the revision, learned about Target-specific
variables, which were very applicable to INSTALL_LIB (which, on a
per-recipe basis, was always receiving the same actual arguments for
its first two formal parameters in every invocation).

  http://www.gnu.org/software/make/manual/html_node/Target_002dspecific.html

(We might be able to make use of those in future refactorings.)

----

Also adds a cleanup pass to get-snapshot.py as well, since the same
problem arises when we unpack libraries from the snapshot archive into
a build directory with a prior snapshot's artifacts.  (I put this step
into the python script rather than the makefile because I wanted to
delay the cleanup pass until after we have at least successfully
downloaded the tarball.  That way, if the download fails, you should
not destroy the previous unarchived snapshot libraries and build
products.)

----

Also reverted whitespace changes to minimize diff.
I plan to put them back in in a dedicated commit elsewhere.
Always eat up mut when parsing general args, fixes #7483
Fix #3225: Incorporate feedback from Graydon.

This is a small follow-up fix to the previous commit: I needed
to quote the right-hand side of the definition for the variable
MATCHES, to handle the case where there are more than one previously
installed libraries in the target directory.
Don't use static default method

 - also removed redundant assignment to is_mutbl
 - updated copyright
Constrain maximum lifetime of stack closures that capture variables to
be limited by the innermost repeating scope.

Fixes #7336.
os: introduce cross-platform MemoryMap bindings

Basically, one may just do:

    MemoryMap::new(16, ~[
      MapExecutable,
      MapReadable,
      MapWritable
    ])

And executable+readable+writable chunk of at least 16 bytes size will be
allocated and freed with the result of `MemoryMap::new`.