Skip to content

Commit 7cb8cf9

Browse files
Merge pull request #1776 from cachemeifyoucan/eng/PR-142709084-release
2 parents ef78a65 + 996f5aa commit 7cb8cf9

File tree

3 files changed

+3
-11
lines changed

3 files changed

+3
-11
lines changed

Sources/SwiftDriver/ExplicitModuleBuilds/ExplicitDependencyBuildPlanner.swift

-5
Original file line numberDiff line numberDiff line change
@@ -264,11 +264,6 @@ public typealias ExternalTargetModuleDetailsMap = [ModuleDependencyId: ExternalT
264264
for dependencyModule in swiftDependencyArtifacts {
265265
inputs.append(TypedVirtualPath(file: dependencyModule.modulePath.path,
266266
type: .swiftModule))
267-
268-
let prebuiltHeaderDependencyPaths = dependencyModule.prebuiltHeaderDependencyPaths ?? []
269-
if cas != nil && !prebuiltHeaderDependencyPaths.isEmpty {
270-
throw DependencyScanningError.unsupportedConfigurationForCaching("module \(dependencyModule.moduleName) has bridging header dependency")
271-
}
272267
}
273268
for moduleArtifactInfo in clangDependencyArtifacts {
274269
let clangModulePath =

Sources/SwiftDriver/SwiftScan/SwiftScan.swift

-3
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ public enum DependencyScanningError: LocalizedError, DiagnosticData, Equatable {
3535
case scanningLibraryInvocationMismatch(String, String)
3636
case scanningLibraryNotFound(AbsolutePath)
3737
case argumentQueryFailed
38-
case unsupportedConfigurationForCaching(String)
3938

4039
public var description: String {
4140
switch self {
@@ -61,8 +60,6 @@ public enum DependencyScanningError: LocalizedError, DiagnosticData, Equatable {
6160
return "Dependency Scanning library not found at path: \(path)"
6261
case .argumentQueryFailed:
6362
return "Supported compiler argument query failed"
64-
case .unsupportedConfigurationForCaching(let reason):
65-
return "Unsupported configuration for -cache-compile-job, consider turn off swift caching: \(reason)"
6663
}
6764
}
6865

Tests/SwiftDriverTests/CachingBuildTests.swift

+3-3
Original file line numberDiff line numberDiff line change
@@ -709,9 +709,9 @@ final class CachingBuildTests: XCTestCase {
709709
main.nativePathString(escaped: true)] + sdkArgumentsForTesting,
710710
env: ProcessEnv.vars,
711711
interModuleDependencyOracle: dependencyOracle)
712-
// This is currently not supported.
713-
XCTAssertThrowsError(try driver.planBuild()) {
714-
XCTAssertEqual($0 as? DependencyScanningError, .unsupportedConfigurationForCaching("module Foo has bridging header dependency"))
712+
let jobs = try driver.planBuild()
713+
for job in jobs {
714+
XCTAssertFalse(job.outputCacheKeys.isEmpty)
715715
}
716716
}
717717
}

0 commit comments

Comments
 (0)