Fold the outcome printer into typing and drop the startup hooks
The type checker printed types and signatures through Oprint, four refs that failed until Res_outcome_printer.setup filled them, and called the ReScript pattern printer, the polymorphic variant printer and the polymorphic variant match compiler through refs that Bs_conditional_initial set at startup. The hooks existed because those modules sat in libraries above the type checker. Now that typing links the printer library, they can be called directly:
- Res_outcome_printer moves from outcome_printer into typing, and Printtyp calls it. Oprint, Res_outcome_printer.setup and the outcome_printer library are gone. - Parmatch calls Pattern_printer, Printtyp calls Res_printer.polyvar_ident_to_string, and Matching calls Polyvar_pattern_match. Matching's unused default implementations, its as_interval and Switch.test_sequence, which only they used, are removed. - Ctype.variant_is_subtype is a function instead of a ref filled with Matching_polyfill.variant_is_subtype. Its body moves into Ctype, checking the base type with Ctype's own helpers, since Typeopt depends on Ctype; get_unboxed_type_representation moves up, unchanged, to precede it. - Bs_conditional_initial keeps the hooks that can't be direct calls (the .cmi loader and the build file store, which tests replace) and moves into typing.
Output is unchanged.