added empty() to Peekable
renamed empty() to is_empty()
Issue #3511 - Rationalize temporary lifetimes.

Major changes:

- Define temporary scopes in a syntax-based way that basically defaults
  to the innermost statement or conditional block, except for in
  a `let` initializer, where we default to the innermost block. Rules
  are documented in the code, but not in the manual (yet).
  See new test run-pass/cleanup-value-scopes.rs for examples.
- Refactors Datum to better define cleanup roles.
- Refactor cleanup scopes to not be tied to basic blocks, permitting
  us to have a very large number of scopes (one per AST node).
- Introduce nascent documentation in trans/doc.rs covering datums and
  cleanup in a more comprehensive way.
Use as_slice() method on option
Remove FIXMEs and add license
Cleanup trait callees
Remove typo
Consider all zero-sized data structures to be voidish, bypassing some "quirky" parts of LLVM (see e.g. LLVM bug 9900) but also generating better code
Don't run 'ar s' on OSX

Apparently this isn't necessary, and it's just causing problems.

Closes #11162
Further refine treatment of voidish arrays
Fix test to account for new temporary lifetime rules, which cause the channel to be dropped prematurely.
Fix uninit() intrinsic when used with empty types
Distinguish zero-size types from those that we return as void
Make main() public in uninit-empty-types
Link lifetimes in `let` patterns just as we do for `match` patterns
Extend temporary lifetimes if there is a ref in an enum binding
too.

Previously I had omitted this case since function calls don't get the same
treatment on the RHS, but it's different on the pattern and is more consistent
-- the goal is to identify `let` statements where `ref` bindings create
interior pointers.
Change expansion of `for` loop to use a `match` statement
so that the "innermost enclosing statement" used for rvalue
temporaries matches up with user expectations
auto merge of #11479 : khodzha/rust/peekable_empty, r=brson

to fix https://github.com/mozilla/rust/issues/11218
Update year on license header
Update years on more license headers