Use the correct logging crate while monomorphing

This makes sure that the top-level crate name is correct when emitting log
statements for a monomorphized function in another crate. This happens by
tracing the monomorphized ID back to the external source and then using that
crate index to get the name of the crate.

Closes #3046
Document logging and remove old functions

This adds a large doc-block to the top of the std::logging module explaining how
to use it. This is mostly just making sure that all the information in the
manual's section about logging is also here (in case someone decides to look
into this module first).

This also removes the old console_{on,off} methods. As far as I can tell, the
functions were only used by the compiler, and there's no reason for them to be
used because they're all turned off by default anyway (maybe they were turned on
by default at some point...)

I believe that this is the final nail in the coffin and closes #5021
Use slice representation for child crate maps
Use slice representation for module entries in CrateMap

Relaxe lifetime of CrateMap as well.
Use &'self str instead of raw char pointer in ModEntry
Add code for older crate map versions, bumped crate map version number
extra: remove commented out 'X' and 'x' formats

These formats are already covered with 'T' | 'X' in line 571 and 'D' | 'x' in
line 446.
auto merge of #9734 : luisbg/rust/master, r=alexcrichton

These formats are already covered with 'T' | 'X' in line 571 and 'D' | 'x' in
line 446.
remove duplicate statement
testsuite: Two tests for fixed bugs

Closes #7246
Closes #7573
auto merge of #9733 : catamorphism/rust/issues-7246-and-7573, r=alexcrichton

r? anybody Closes #7246
Closes #7573
auto merge of #9729 : dwrensha/rust/regionmanip-cleanup, r=catamorphism
docs / rustpkg: Document `rustpkg test` more

Talk about `rustpkg test` in the tutorial, and update its usage message.
Implement feature-gating for the compiler

A few features are now hidden behind various #[feature(...)] directives. These
include struct-like enum variants, glob imports, and macro_rules! invocations.

Closes #9304
Closes #9305
Closes #9306
Closes #9331
rustpkg: Fix fetching remote packages

Closes #9193
auto merge of #9738 : catamorphism/rust/rustpkg-test-docs-need-to-submit, r=alexcrichton

r? anybody Talk about `rustpkg test` in the tutorial, and update its usage message.

@steveklabnik, it would be great if you could look this over :-)
Fix a typo in std::ops documentation
Clearer error message for external trait and type

The old error message implied that external traits could never
be implemented locally.
auto merge of #9682 : skade/rust/clearer-error-message-for-external-type-and-trait, r=alexcrichton

The old error message implied that external traits could never
be implemented locally.
get_crate_map returns an Option