mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Enable full SIL verification with -compiler-assertions
This commit is contained in:
@@ -2749,6 +2749,7 @@ static bool ParseSILArgs(SILOptions &Opts, ArgList &Args,
|
||||
Opts.EnableLifetimeDependenceDiagnostics);
|
||||
|
||||
Opts.VerifyAll |= Args.hasArg(OPT_sil_verify_all);
|
||||
Opts.VerifyAll |= CONDITIONAL_ASSERT_enabled();
|
||||
Opts.VerifyNone |= Args.hasArg(OPT_sil_verify_none);
|
||||
Opts.DebugSerialization |= Args.hasArg(OPT_sil_debug_serialization);
|
||||
Opts.EmitVerboseSIL |= Args.hasArg(OPT_emit_verbose_sil);
|
||||
@@ -2769,6 +2770,7 @@ static bool ParseSILArgs(SILOptions &Opts, ArgList &Args,
|
||||
Opts.DisableSILPartialApply |=
|
||||
Args.hasArg(OPT_disable_sil_partial_apply);
|
||||
Opts.VerifySILOwnership &= !Args.hasArg(OPT_disable_sil_ownership_verifier);
|
||||
Opts.VerifySILOwnership |= CONDITIONAL_ASSERT_enabled();
|
||||
Opts.EnableDynamicReplacementCanCallPreviousImplementation = !Args.hasArg(
|
||||
OPT_disable_previous_implementation_calls_in_dynamic_replacements);
|
||||
Opts.ParseStdlib = FEOpts.ParseStdlib;
|
||||
@@ -3652,6 +3654,8 @@ bool CompilerInvocation::parseArgs(
|
||||
return true;
|
||||
}
|
||||
|
||||
ParseAssertionArgs(ParsedArgs);
|
||||
|
||||
if (ParseFrontendArgs(FrontendOpts, ParsedArgs, Diags,
|
||||
ConfigurationFileBuffers)) {
|
||||
return true;
|
||||
@@ -3668,8 +3672,6 @@ bool CompilerInvocation::parseArgs(
|
||||
return true;
|
||||
}
|
||||
|
||||
ParseAssertionArgs(ParsedArgs);
|
||||
|
||||
if (ParseLangArgs(LangOpts, ParsedArgs, Diags, FrontendOpts)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user