Deal with catching generic exceptions
Summary: These have the same problem that `instanceof` does, that you
can't do `catch (Foo<Generic> $e)` since we don't have reified generics.
So we should do the same hack we do for `instanceof`, setting each of
the type parameters to `Tunresolved []` -- this is clearly better than
setting them to the empty list like we do now, which leads to really
weird error messages like those in the github issue.
We could also just ban generic exceptions altogether, but that seems
like a shortsighted restriction since we may want to add reified generics
at some point in the future.
Fixes https://github.com/facebook/hhvm/issues/3093
Reviewed By: @elgenie
Differential Revision:
D1661066
Signature: t1:
1661066:
1415217726:
41297e94d8546ee3aaf83ae4f4010d91ab19ccb0