Merge pull request #40535 from nate-chandler/lexical_lifetimes/allow-flags-compatible-with-move-only-to-be-passed

This commit is contained in:
swift-ci
2021-12-13 18:02:07 -08:00
committed by GitHub

View File

@@ -1503,7 +1503,7 @@ static bool ParseSILArgs(SILOptions &Opts, ArgList &Args,
}
if (Args.hasArg(OPT_enable_experimental_move_only) &&
(enableLexicalBorrowScopesFlag.getValueOr(false))) {
!enableLexicalBorrowScopesFlag.getValueOr(true)) {
// Error if move-only is enabled and lexical borrow scopes--on which it
// depends--has been disabled.
Diags.diagnose(SourceLoc(), diag::error_invalid_arg_combination,
@@ -1513,7 +1513,7 @@ static bool ParseSILArgs(SILOptions &Opts, ArgList &Args,
}
if (Args.hasArg(OPT_enable_experimental_move_only) &&
(enableLexicalLifetimesFlag.getValueOr(false))) {
!enableLexicalLifetimesFlag.getValueOr(true)) {
// Error if move-only is enabled and lexical lifetimes--on which it
// depends--has been disabled.
Diags.diagnose(SourceLoc(), diag::error_invalid_arg_combination,