[Sema] Introduce remarks about the source of each decl in API

Using `-Rmodule-api-import` the compiler prints a remark about the
import bringing in every decl used in public function signatures or
inlinable code. It also remarks on the source of conformances where they
are used and the source of typealias underlying types.
This commit is contained in:
Alexis Laferrière
2023-09-26 18:08:19 -07:00
parent a0b848ea96
commit c15a576a1c
7 changed files with 215 additions and 0 deletions

View File

@@ -1021,6 +1021,7 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
Opts.EnableModuleLoadingRemarks = Args.hasArg(OPT_remark_loading_module);
Opts.EnableModuleRecoveryRemarks = Args.hasArg(OPT_remark_module_recovery);
Opts.EnableModuleApiImportRemarks = Args.hasArg(OPT_remark_module_api_import);
Opts.EnableMacroLoadingRemarks = Args.hasArg(OPT_remark_macro_loading);
Opts.EnableIndexingSystemModuleRemarks = Args.hasArg(OPT_remark_indexing_system_module);