fs: use an iterative algorithm for 'mkdir_recursive'

as requested in #6109
fs: use an iterative algorithm for 'rmdir_recursive'

For now, the windows version uses stat, just as before.
We should switch back to lstat as soon as #12795 is closed.
fs: units tests for mkdir_recusive and rmdir_recursive

The rmdir test is blocked by #12795 on windows.
std::unicode: remove unused category tables
Implement lower, upper case conversion for char
Remove code duplication

Remove whitespace

Update documentation for to_uppercase, to_lowercase
collections: move hashmap's example to the struct.

Most people go straight to the struct, not looking at the module, so the
example was well hidden.
collections: Don't recurse in hashmap robin_hood

This switches a "tail call" to a manual loop to get around LLVM not optimizing
to a tail call.

Close #12860
auto merge of #12561 : pzol/rust/char-case, r=alexcrichton

Added common and simple case folding, i.e. mapping one to one character mapping. For more information see http://www.unicode.org/faq/casemap_charprop.html

Removed auto-generated dead code which wasn't used.
auto merge of #12573 : lbonn/rust/unrecurs, r=alexcrichton

As mentioned in #6109, ```mkdir_recursive``` doesn't really need to use recursive calls, so here is an iterative version.
The other points of the proposed overhaul (renaming and existing permissions) still need to be resolved.

I also bundled an iterative ```rmdir_recursive```, for the same reason.

Please do not hesitate to provide feedback on style as this is my first code change in rust.
std: Rename Chan/Port types and constructor

* Chan<T> => Sender<T>
* Port<T> => Receiver<T>
* Chan::new() => channel()
* constructor returns (Sender, Receiver) instead of (Receiver, Sender)
* local variables named `port` renamed to `rx`
* local variables named `chan` renamed to `tx`

Closes #11765
Refactored while_some (libstd/option.rs)

The old 'while' needed to match 2 times for each iteration. With the new
'loop' there is just one match needed.

I have also replaced 'blk' by 'f' to be more consistent with parameter
names in other functions that are implemented for Option
auto merge of #12815 : alexcrichton/rust/chan-rename, r=brson

* Chan<T> => Sender<T>
* Port<T> => Receiver<T>
* Chan::new() => channel()
* constructor returns (Sender, Receiver) instead of (Receiver, Sender)
* local variables named `port` renamed to `rx`
* local variables named `chan` renamed to `tx`

Closes #11765
Fix and improve inline assembly.

Read+write modifier
Some documentation in asm.rs
rpass and cfail tests
io: Bind to shutdown() for TCP streams

This is something that is plausibly useful, and is provided by libuv. This is
not currently surfaced as part of the `TcpStream` type, but it may possibly
appear in the future. For now only the raw functionality is provided through the
Rtio objects.
rustc: make stack traces print for .span_bug/.bug.

Previously a call to either of those to diagnostic printers would defer
to the `fatal` equivalents, which explicitly silence the stderr
printing, including a stack trace from `RUST_LOG=std::rt::backtrace`.

This splits the bug printers out to their own diagnostic type so that
things work properly.

Also, this removes the `Ok(...)` that was being printed around the
subtask's stderr output.
std: Demangle more escapes in backtraces

The rust compiler not only outputs symbols in the form that C++ does, but it
also mangle symbols like '&' and '~' to special compiler-defined escape
sequences. For convenience, these symbols are demangled when printing
backtraces.
rustc: Prevent collisions in names of closures

This commit goes back to using `gensym` to generate unique tokens to put into
the names of closures, allowing closures to be able to get demangled in
backtraces.

Closes #12400
lint: add lint for use of a `~[T]`.

This is useless at the moment (since pretty much every crate uses
`~[]`), but should help avoid regressions once completely removed from a
crate.
std: render the vec_ng docs.

These are wildly incomplete, but having something there is better than
nothing, e.g. so that people know it exists, and many of the functions
behaviour can be guessed from the name or by checking the source: it's
knowing they exist at all that's the hard part.