[SE-0160] Add an opt-in warning about deprecated @objc inference.

Introduce an opt-in warning (enabled by the frontend option
-warn-swift3-objc-inference) for each declaration for which @objc is
inferred based on Swift 3 rules that no longer apply after SE-0160.
This commit is contained in:
Doug Gregor
2017-03-27 09:56:46 -07:00
parent afef3421a8
commit 2c1981fe9d
6 changed files with 73 additions and 2 deletions

View File

@@ -955,6 +955,7 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
}
Opts.EnableAppExtensionRestrictions |= Args.hasArg(OPT_enable_app_extension);
Opts.WarnSwift3ObjCInference |= Args.hasArg(OPT_warn_swift3_objc_inference);
llvm::Triple Target = Opts.Target;
StringRef TargetArg;