Skip to content

[NFC] Workaround compiler issue by renaming some optionals #498

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ public struct BidirectionalMap<T1: Hashable, T2: Hashable>: Equatable, Sequence
return value
}
set {
if let newValue = newValue {
map1[key] = newValue
map2[newValue] = key
if let someNewValue = newValue {
map1[key] = someNewValue
map2[someNewValue] = key
return
}
if let oldValue = map1.removeValue(forKey: key) {
Expand All @@ -45,9 +45,9 @@ public struct BidirectionalMap<T1: Hashable, T2: Hashable>: Equatable, Sequence
return value
}
set {
if let newValue = newValue {
map2[key] = newValue
map1[newValue] = key
if let someNewValue = newValue {
map2[key] = someNewValue
map1[someNewValue] = key
return
}
if let oldValue = map2.removeValue(forKey: key) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,17 +126,17 @@ extension IncrementalCompilationState.InitialStateComputer {
) -> (ModuleDependencyGraph, Set<TypedVirtualPath>)?
{
let dependencyGraphPath = buildRecordInfo.dependencyGraphPath
let graph: ModuleDependencyGraph?
let graphIfPresent: ModuleDependencyGraph?
do {
graph = try ModuleDependencyGraph.read( from: dependencyGraphPath, info: self)
graphIfPresent = try ModuleDependencyGraph.read( from: dependencyGraphPath, info: self)
}
catch {
diagnosticEngine.emit(
warning: "Could not read \(dependencyGraphPath), will not do cross-module incremental builds")
reporter?.reportDisablingIncrementalBuild("Could not read priors from \(dependencyGraphPath)")
return nil
}
guard let graph = graph
guard let graph = graphIfPresent
else {
return buildInitialGraphFromSwiftDepsAndCollectInputsInvalidatedByChangedExternals()
}
Expand Down