Fix `ty_trait` variance inference bug

that variance inference pass doesn't take lifetime parameters and
mutability of a trait reference into consideration.

Note that `libserialize` won't compile duo to additional lifetime
variance constraints; the fix for that is not part of the commit. One
still gets a working stage1 rustc, though.
Incorporate variance into typeck

Implements RFC for tweaked variance inference rules.

Note the `libarena` won't compile as discussed in IRC. It makes an
interesting case for RFC so the fix for it is not included. A working
stage1 rustc can be built without the fix anyway.
Fix fallout for stage1
Fix fallout in tests
Fix fallout for librustdoc

Gets rid of `ExternFn`. It is long over due and in this case confuses
type substitution. The type `Some(extern "C" fn)` gets expanded to
`Some(extern "C" extern fn)` that leads to LLVM assertion failure.