Skip to content

Commit 69fc09f

Browse files
committed
[Frontend] Allow building without host Swift
There's no `swift_ASTGen_destroySourceFile` when we're not building ASTGen.
1 parent 04e100d commit 69fc09f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/Frontend/PrintingDiagnosticConsumer.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -576,7 +576,9 @@ PrintingDiagnosticConsumer::PrintingDiagnosticConsumer(
576576
: Stream(stream) {}
577577

578578
PrintingDiagnosticConsumer::~PrintingDiagnosticConsumer() {
579+
#if SWIFT_BUILD_SWIFT_SYNTAX
579580
for (const auto &sourceFileSyntax : sourceFileSyntax) {
580581
swift_ASTGen_destroySourceFile(sourceFileSyntax.second);
581582
}
583+
#endif
582584
}

0 commit comments

Comments
 (0)