Semantic Diff

#8991 Remove dead code, stale comments and unused test inputs

1 commit

9e2f371482f529406d70df0565784aa8df3554e9..pr-8991

8427be4c9 · Christoph Knittel with Claude Opus 5.5 · Oct 23, 2026

Remove dead code, stale comments and unused test inputs

Why

Recent removals left definitions without callers, which no warning reports because they are exported or in a module without an interface: Cmi_format.output_cmi, the always-None cmt_interface_digest, the read of a cmt after an embedded cmi (unreachable since the magic bumps of #8805 and #8928), Oprint.out_type_extension, Ext_namespace.try_split_module_name and Ast_untagged_variants.block_type_can_be_undefined. Comments that promised older .cmt layouts, a JSX transform rejection that #8944 made a deprecation, and a TODO for a removed warning are corrected, and the empty rescript_compiler_main.mli and three unused test inputs removed.

Review

  • Why does the cmt magic number change? Removing cmt_interface_digest changes the marshalled cmt_infos record, so .cmt files of the previous layout must be rejected rather than misread: T047 becomes T048.