[hack] Look up class methods lazily using the linearization
[hack] Look up class methods lazily using the linearization

Summary:
This diff introduces the Decl_inheritance module, which will provide the implementation of lazy lookup for all class members. This diff implements lazy lookup for methods only; other class member kinds are covered in future diffs in this stack.

This diff also introduces a companion module Typing_inheritance, used to verify overrides of methods against every previously-inherited version which was overridden. Decl_inheritance provides `all_inherited_methods` and `all_inherited_smethods` for consumption by Typing_inheritance. Currently, Typing_inheritance is used only for detection of `<<__Override>>` annotations on methods which do not override any other method, but we could choose to move more checks into it in the future.

Because we now verify overrides in Typing rather than Decl, the test case integration_ml/test_failed_decl must be changed. This test case exercises behavior in the presence of Decl-phase errors, but the override error is now a Typing-phase error, so we must replace that error with some other error which is still emitted during the Decl phase.

Differential Revision: D13409652

fbshipit-source-id: c7a9c8ea4c9d26a42f533a3f1866620749230a0a

gabelevi/flow,gabelevi/flow,mroch/flow,gabelevi/flow,samwgoldman/flow,facebook/flow,gabelevi/flow,mroch/flow,facebook/flow,samwgoldman/flow,samwgoldman/flow,mroch/flow,samwgoldman/flow,gabelevi/flow,samwgoldman/flow,facebook/flow,gabelevi/flow,facebook/flow,facebook/flow,mroch/flow,mroch/flow,facebook/flow,samwgoldman/flow,samwgoldman/flow,facebook/flow,gabelevi/flow,mroch/flow,mroch/flow