[Frontend] Add -print-supported-features option

This is a replacement for `-emit-supported-features` that prints
all of the upcoming/experimental features supported by the compiler
with some additional meta information in JSON format to stdout.

(cherry picked from commit 55bd906906)
This commit is contained in:
Pavel Yaskevich
2025-04-14 16:57:11 -07:00
parent e92e9dff0c
commit e477143d58
9 changed files with 153 additions and 0 deletions

View File

@@ -206,6 +206,10 @@ bool ArgsToFrontendOptionsConverter::convert(
Opts.PrintTargetInfo = true;
}
if (Args.hasArg(OPT_print_supported_features)) {
Opts.PrintSupportedFeatures = true;
}
if (const Arg *A = Args.getLastArg(OPT_verify_generic_signatures)) {
Opts.VerifyGenericSignaturesInModule = A->getValue();
}