mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Frontend: Parse diagnostic options earlier.
Diagnostics may be emitted while parsing command line arguments. This implies that the options which affect how diagnostics are emitted and presented need to be parsed first.
This commit is contained in:
@@ -2248,10 +2248,6 @@ InterfaceSubContextDelegateImpl::runInSubCompilerInstance(StringRef moduleName,
|
||||
subInstance.addDiagnosticConsumer(&noopConsumer);
|
||||
}
|
||||
|
||||
// Eagerly suppress warnings if necessary, before parsing arguments.
|
||||
if (subInvocation.getDiagnosticOptions().SuppressWarnings)
|
||||
subInstance.getDiags().setSuppressWarnings(true);
|
||||
|
||||
SwiftInterfaceInfo interfaceInfo;
|
||||
// Extract compiler arguments from the interface file and use them to configure
|
||||
// the compiler invocation.
|
||||
|
||||
Reference in New Issue
Block a user