@@ -18,7 +18,7 @@ import SwiftOptions
18
18
/// compilation record).
19
19
///
20
20
/// This info is always written, but only read for incremental compilation.
21
- final class BuildRecordInfo {
21
+ @ _spi ( Testing ) public final class BuildRecordInfo {
22
22
/// A pair of a `Job` and the `ProcessResult` corresponding to the outcome of
23
23
/// its execution during this compilation session.
24
24
struct JobResult {
@@ -122,16 +122,19 @@ final class BuildRecordInfo {
122
122
}
123
123
124
124
/// Write out the build record.
125
- /// `Jobs` must include all of the compilation jobs.
126
- /// `Inputs` will hold all the primary inputs that were not compiled because of incremental compilation
127
- func writeBuildRecord( _ jobs: [ Job ] , _ skippedInputs: Set < TypedVirtualPath > ? ) {
125
+ ///
126
+ /// - Parameters:
127
+ /// - jobs: All compilation jobs formed during this build.
128
+ /// - skippedInputs: All primary inputs that were not compiled because the
129
+ /// incremental build plan determined they could be
130
+ /// skipped.
131
+ func writeBuildRecord( _ jobs: [ Job ] , _ skippedInputs: Set < TypedVirtualPath > ? ) {
128
132
guard let absPath = buildRecordPath. absolutePath else {
129
133
diagnosticEngine. emit (
130
134
. warning_could_not_write_build_record_not_absolutePath( buildRecordPath) )
131
135
return
132
136
}
133
137
preservePreviousBuildRecord ( absPath)
134
-
135
138
136
139
let buildRecord = self . confinementQueue. sync {
137
140
BuildRecord (
@@ -155,7 +158,7 @@ final class BuildRecordInfo {
155
158
} catch {
156
159
diagnosticEngine. emit ( . warning_could_not_write_build_record( absPath) )
157
160
}
158
- }
161
+ }
159
162
160
163
/// Before writing to the dependencies file path, preserve any previous file
161
164
/// that may have been there. No error handling -- this is just a nicety, it
0 commit comments