Skip to content

Commit e7f7a25

Browse files
Remove duplicate initializer for SemanticVersion
1 parent f35979e commit e7f7a25

File tree

2 files changed

+1
-8
lines changed

2 files changed

+1
-8
lines changed

Sources/SwiftDocC/Model/Rendering/DocumentationContentRenderer.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ public class DocumentationContentRenderer {
230230
}
231231

232232
// Verify that the current platform is in beta and the version number matches the introduced platform version.
233-
guard current.beta && SemanticVersion(symbolGraphVersion: introduced) >= SemanticVersion(versionTriplet: current.version) else {
233+
guard current.beta && SemanticVersion(introduced) >= SemanticVersion(versionTriplet: current.version) else {
234234
return false
235235
}
236236
}

Sources/SwiftDocC/Model/Rendering/SemanticVersion.swift

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,6 @@ public struct SemanticVersion: Codable, Equatable, Comparable, CustomStringConve
5353
self.buildMetadata = try container.decodeIfPresent(String.self, forKey: .buildMetadata)
5454
}
5555

56-
/// Create a semantic version from a Symbol Kit semantic version.
57-
init(symbolGraphVersion: SymbolGraph.SemanticVersion) {
58-
self.major = symbolGraphVersion.major
59-
self.minor = symbolGraphVersion.minor
60-
self.patch = symbolGraphVersion.patch
61-
}
62-
6356
/// Create a semantic version from a version triplet
6457
/// TODO: https://github.com/swiftlang/swift-docc/issues/970
6558
/// Migrate all the code to use semantic versions, and not version triplets.

0 commit comments

Comments
 (0)