Skip to content

Commit 60e12b8

Browse files
author
David Ungar
committed
Capitalize the reason
1 parent 418b607 commit 60e12b8

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Sources/SwiftDriver/IncrementalCompilation/DependencyKey.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ extension DependencyKey.Designator: Comparable {
370370

371371
// MARK: - InvalidationReason
372372
extension ExternalDependency {
373-
public enum InvalidationReason: String {
373+
public enum InvalidationReason: String, CustomStringConvertible {
374374
case added, changed, testing
375375
init?(_ graph: ModuleDependencyGraph,
376376
isNewToTheGraph: Bool ,
@@ -385,5 +385,6 @@ extension ExternalDependency {
385385
}
386386
return nil
387387
}
388+
public var description: String { rawValue }
388389
}
389390
}

Sources/SwiftDriver/IncrementalCompilation/IncrementalCompilationState.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,9 +436,10 @@ extension IncrementalCompilationState {
436436
)
437437
where Nodes.Element == ModuleDependencyGraph.Node
438438
{
439+
let whyString = why.description.capitalized
439440
let depString = externalDependency.shortDescription
440441
for node in nodes {
441-
report("\(why): \(depString) -> \(node)")
442+
report("\(whyString): \(depString) -> \(node)")
442443
}
443444
}
444445
}

0 commit comments

Comments
 (0)