Fix stack overflow bug
Summary:
D43271340 (https://github.com/facebook/hhvm/commit/
9f4631d2fabbe5d38f6257d76a250925d4131a1a) introduced a stack overflow where `supportdyn` wrappers piled up in the environment. That diff make union and intersection try to aggressively avoid wrapping with supportdyn, including checking if the type to be wrapped was a subtype of supportdyn<mixed> already. The fix is to use a simpler syntactic check when union and intersection is wrapping with supportdyn.
Reviewed By: vassilmladenov
Differential Revision:
D43395263
fbshipit-source-id:
15e162f2af4759ebf650d75924805a469647bde3