Optimize Typing_phase.localize for the common case of loading a class
Summary: When localizing `Tapply`, we first check if it is a typedef using `Typing_env.is_typedef`. This will require fetching data from shared memory from the Naming_heap. I didn't think this was a big deal, since we also need to refer to the naming heap when resolving a class anyways. However there is a chance of saving some work if the class was already declared. In that case we would be able to fetch it the Classes heap, avoiding the cost completely of going to the Naming heap.
Reviewed By: andrewjkennedy
Differential Revision:
D22461080
fbshipit-source-id:
ce387b0cc37c5914269b1c6c91b0f9191e266619