remove DiagPrinter directly from the CompilerInvocation

This commit is contained in:
Victoria Mitchell
2020-12-11 08:30:32 -07:00
parent 85ad81625c
commit 5bf567f5f6

View File

@@ -250,7 +250,7 @@ int swift_symbolgraph_extract_main(ArrayRef<const char *> Args, const char *Argv
// since some SDK modules can cause errors in the getModuleByName() call. The call // since some SDK modules can cause errors in the getModuleByName() call. The call
// itself will properly return nullptr after this failure, so for our purposes we // itself will properly return nullptr after this failure, so for our purposes we
// don't need to print these errors. // don't need to print these errors.
CI.getDiags().removeConsumer(DiagPrinter); CI.removeDiagnosticConsumer(&DiagPrinter);
for (const auto &ModuleName : VisibleModuleNames) { for (const auto &ModuleName : VisibleModuleNames) {
if (ModuleName.str().startswith("_")) { if (ModuleName.str().startswith("_")) {