Error messages related to magic methods

Summary: This diff implements many small error messages thrown around magic methods.

Reviewed By: @ptarjan

Differential Revision: D1423455
Fix autoloading for "type" and "newtype" statements

Summary: If the name on the right hand side of a "type" or "newtype" statement does
not name an existing class/interface/trait or an existing type alias, HHVM
tries both class-autoloading and type-autoloading. The problem is that if
class-autoloading doesn't find anything, HHVM calls the failure callback
before trying type-autoloading, which can cause problems for correct
programs (see the test cases).

This diff fixes HHVM to try both class-autoloading and type-autoloading
before calling the failure callback for "type" and "newtype" statements.

Reviewed By: @elgenie

Differential Revision: D1410570
typechecker: keep track of type params for require extends X<T1, T2, ...>

Summary: ... these were previously being thrown away and replaced with the
 type params of the containing trait and interface, usually working
 simply because the typechecker is (too) tolerant of classes without
 bound type params. The code for this is somewhat involved and
 complicated by the fact that a `require extends Foo<T1, T2>` requires
 the type variables `T1` and `T2` to be substituted juuuuust right in
 each place they're used.

Reviewed By: @jwatzman

Differential Revision: D1410558