Skip to content

Commit 2d47a9b

Browse files
committed
DirectoryContentsTask::inputsAvailable may assert due to missing output
rdar://78841971
1 parent 3c99ab5 commit 2d47a9b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/BuildSystem/BuildSystem.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -816,6 +816,12 @@ class DirectoryContentsTask : public Task {
816816
return;
817817
}
818818

819+
if (directoryValue.isMissingOutput()) {
820+
// Rewrite a missing output as a missing input build value for this node, both conceptually and as a hedge against violating the downstream expectations of other rules.
821+
ti.complete(BuildValue::makeMissingInput().toData());
822+
return;
823+
}
824+
819825
if (directoryValue.isFailedInput()) {
820826
ti.complete(BuildValue::makeFailedInput().toData());
821827
return;

0 commit comments

Comments
 (0)