add `#[thread_local]` attribute

This provides a building block for fast thread-local storage. It does
not change the safety semantics of `static mut`.

Closes #10310
port the runtime to `#[thread_local]`
add a thread_local feature gate
auto merge of #10312 : thestinger/rust/thread_local, r=alexcritchton

This provides a building block for fast thread-local storage. It does
not change the safety semantics of `static mut`.

Closes #10310
Add SmallVector to libsyntax
Support multiple item macros

Closes #4375
Clean up SmallVector use a bit
auto merge of #10649 : sfackler/rust/multi-macro, r=alexcrichton

The majority of this change is modifying some of the `ast_visit` methods to return multiple values.

It's prohibitively expensive to allocate a `~[Foo]` every time a statement, declaration, item, etc is visited, especially since the vast majority will have 0 or 1 elements. I've added a `SmallVector` class that avoids allocation in the 0 and 1 element cases to take care of that.