Add scope guards to libstd

This adds a struct which runs a block when it falls out of scope,
similar to `scope` in D or `defer` in Go. Using this module directly
requires code to assign the ScopeGuard struct to a variable manually
which is unnecessary in many situations.

It'd be nice to add a syntax extension to automatically expand
```rust
scope!(success) {
    ...
}
```
to something like
```rust
let __scope__<FILE>_<LINE>_<COL> = ::std::scope::guard(::std::scope::Success, { ... });
```
but I don't think that syntax extensions can currently expand to statements as opposed to expressions or items and I'm not familiar enough with libsyntax to add it easily. I put this in libstd instead of libextra since it'll need to be there for the syntax extension to work reasonably.

cc #9835