Add --enable-throw-without-try option to suppress warning about missing 'try'.

To be used by the debugger so expression parsing doesn't require 'try'
everywhere. <rdar://problem/20356764>

Swift SVN r27949
This commit is contained in:
Chris Willmore
2015-04-29 23:51:40 +00:00
parent 018ce2edfc
commit c7a0963d60
5 changed files with 29 additions and 1 deletions

View File

@@ -667,6 +667,8 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
Opts.EnableDollarIdentifiers = true;
Opts.Playground |= Args.hasArg(OPT_playground);
Opts.EnableThrowWithoutTry |= Args.hasArg(OPT_enable_throw_without_try);
if (auto A = Args.getLastArg(OPT_enable_objc_attr_requires_foundation_module,
OPT_disable_objc_attr_requires_foundation_module)) {
Opts.EnableObjCAttrRequiresFoundation