@@ -61,7 +61,7 @@ extension Driver {
61
61
/// Plan a standard compilation, which produces jobs for compiling separate
62
62
/// primary files.
63
63
private mutating func planStandardCompile( ) throws
64
- -> ( [ Job ] , IncrementalCompilationState ? ) {
64
+ -> ( [ Job ] , IncrementalCompilationState ? , InterModuleDependencyGraph ? ) {
65
65
precondition ( compilerMode. isStandardCompilationForPlanning,
66
66
" compiler mode \( compilerMode) is handled elsewhere " )
67
67
// Determine the initial state for incremental compilation that is required during
@@ -101,7 +101,7 @@ extension Driver {
101
101
jobCreatingPch: jobsInPhases. allJobs. first ( where: { $0. kind == . generatePCH} ) )
102
102
}
103
103
104
- return ( batchedJobs, incrementalCompilationState)
104
+ return ( batchedJobs, incrementalCompilationState, interModuleDependencyGraph )
105
105
}
106
106
107
107
/// If performing an explicit module build, compute an inter-module dependency graph.
@@ -750,17 +750,17 @@ extension Driver {
750
750
/// Plan a build by producing a set of jobs to complete the build.
751
751
/// Should be private, but compiler bug
752
752
/*private*/ mutating func planPossiblyIncrementalBuild( ) throws
753
- -> ( [ Job ] , IncrementalCompilationState ? ) {
753
+ -> ( [ Job ] , IncrementalCompilationState ? , InterModuleDependencyGraph ? ) {
754
754
755
755
if let job = try immediateForwardingJob ( ) {
756
- return ( [ job] , nil )
756
+ return ( [ job] , nil , nil )
757
757
}
758
758
759
759
// The REPL doesn't require input files, but all other modes do.
760
760
guard !inputFiles. isEmpty || compilerMode == . repl || compilerMode == . intro else {
761
761
if parsedOptions. hasArgument ( . v) {
762
762
// `swiftc -v` is allowed and prints version information.
763
- return ( [ ] , nil )
763
+ return ( [ ] , nil , nil )
764
764
}
765
765
throw Error . noInputFiles
766
766
}
@@ -771,7 +771,7 @@ extension Driver {
771
771
if !inputFiles. isEmpty {
772
772
throw PlanningError . replReceivedInput
773
773
}
774
- return ( [ try replJob ( ) ] , nil )
774
+ return ( [ try replJob ( ) ] , nil , nil )
775
775
776
776
case . immediate:
777
777
var jobs : [ Job ] = [ ]
@@ -783,7 +783,7 @@ extension Driver {
783
783
initialIncrementalState: nil ,
784
784
addJob: { jobs. append ( $0) } )
785
785
jobs. append ( try interpretJob ( inputs: inputFiles) )
786
- return ( jobs, nil )
786
+ return ( jobs, nil , nil )
787
787
788
788
case . standardCompile, . batchCompile, . singleCompile:
789
789
return try planStandardCompile ( )
@@ -792,15 +792,15 @@ extension Driver {
792
792
if inputFiles. count != 1 {
793
793
throw PlanningError . emitPCMWrongInputFiles
794
794
}
795
- return ( [ try generateEmitPCMJob ( input: inputFiles. first!) ] , nil )
795
+ return ( [ try generateEmitPCMJob ( input: inputFiles. first!) ] , nil , nil )
796
796
797
797
case . dumpPCM:
798
798
if inputFiles. count != 1 {
799
799
throw PlanningError . dumpPCMWrongInputFiles
800
800
}
801
- return ( [ try generateDumpPCMJob ( input: inputFiles. first!) ] , nil )
801
+ return ( [ try generateDumpPCMJob ( input: inputFiles. first!) ] , nil , nil )
802
802
case . intro:
803
- return ( try helpIntroJobs ( ) , nil )
803
+ return ( try helpIntroJobs ( ) , nil , nil )
804
804
}
805
805
}
806
806
}
0 commit comments