mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Check attributes in @abi attr
This commit compares the attributes on the decl inside the `@abi` attribute to those in the decl it’s attached to, diagnosing ABI-incompatible differences. It also rejects many attributes that don’t need to be specified in the `@abi` attribute, such as ObjC-ness, access control, or ABI-neutral traits like `@discardableResult`, so developers know to remove them.
This commit is contained in:
@@ -1422,6 +1422,8 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
|
||||
|
||||
Opts.EnableSkipExplicitInterfaceModuleBuildRemarks = Args.hasArg(OPT_remark_skip_explicit_interface_build);
|
||||
|
||||
Opts.EnableABIInferenceRemarks = Args.hasArg(OPT_remark_abi_inference);
|
||||
|
||||
if (Args.hasArg(OPT_experimental_skip_non_exportable_decls)) {
|
||||
// Only allow -experimental-skip-non-exportable-decls if either library
|
||||
// evolution is enabled (in which case the module's ABI is independent of
|
||||
|
||||
Reference in New Issue
Block a user