Skip to content

Commit 82c182c

Browse files
committed
Merge branch 'main' into more-swift-concurrency-1
2 parents 20971fa + d842fdd commit 82c182c

File tree

104 files changed

+7578
-925
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

104 files changed

+7578
-925
lines changed

Package.swift

Lines changed: 48 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
This source file is part of the Swift.org open source project
44

5-
Copyright (c) 2021-2024 Apple Inc. and the Swift project authors
5+
Copyright (c) 2021-2025 Apple Inc. and the Swift project authors
66
Licensed under Apache License v2.0 with Runtime Library Exception
77

88
See https://swift.org/LICENSE.txt for license information
@@ -43,6 +43,8 @@ let package = Package(
4343
.target(
4444
name: "SwiftDocC",
4545
dependencies: [
46+
.target(name: "DocCCommon"),
47+
.target(name: "DocCHTML"),
4648
.product(name: "Markdown", package: "swift-markdown"),
4749
.product(name: "SymbolKit", package: "swift-docc-symbolkit"),
4850
.product(name: "CLMDB", package: "swift-lmdb"),
@@ -55,6 +57,7 @@ let package = Package(
5557
name: "SwiftDocCTests",
5658
dependencies: [
5759
.target(name: "SwiftDocC"),
60+
.target(name: "DocCCommon"),
5861
.target(name: "SwiftDocCTestUtilities"),
5962
],
6063
resources: [
@@ -70,6 +73,7 @@ let package = Package(
7073
name: "SwiftDocCUtilities",
7174
dependencies: [
7275
.target(name: "SwiftDocC"),
76+
.target(name: "DocCCommon"),
7377
.product(name: "NIOHTTP1", package: "swift-nio", condition: .when(platforms: [.macOS, .iOS, .linux, .android])),
7478
.product(name: "ArgumentParser", package: "swift-argument-parser")
7579
],
@@ -81,6 +85,7 @@ let package = Package(
8185
dependencies: [
8286
.target(name: "SwiftDocCUtilities"),
8387
.target(name: "SwiftDocC"),
88+
.target(name: "DocCCommon"),
8489
.target(name: "SwiftDocCTestUtilities"),
8590
],
8691
resources: [
@@ -95,6 +100,7 @@ let package = Package(
95100
name: "SwiftDocCTestUtilities",
96101
dependencies: [
97102
.target(name: "SwiftDocC"),
103+
.target(name: "DocCCommon"),
98104
.product(name: "SymbolKit", package: "swift-docc-symbolkit"),
99105
],
100106
swiftSettings: swiftSettings
@@ -109,6 +115,47 @@ let package = Package(
109115
exclude: ["CMakeLists.txt"],
110116
swiftSettings: swiftSettings
111117
),
118+
119+
// A few common types and core functionality that's useable by all other targets.
120+
.target(
121+
name: "DocCCommon",
122+
dependencies: [
123+
// This target shouldn't have any local dependencies so that all other targets can depend on it.
124+
// We can add dependencies on SymbolKit and Markdown here but they're not needed yet.
125+
],
126+
exclude: ["CMakeLists.txt"],
127+
swiftSettings: [.swiftLanguageMode(.v6)]
128+
),
129+
130+
.testTarget(
131+
name: "DocCCommonTests",
132+
dependencies: [
133+
.target(name: "DocCCommon"),
134+
.target(name: "SwiftDocCTestUtilities"),
135+
],
136+
swiftSettings: [.swiftLanguageMode(.v6)]
137+
),
138+
139+
.target(
140+
name: "DocCHTML",
141+
dependencies: [
142+
.target(name: "DocCCommon"),
143+
.product(name: "Markdown", package: "swift-markdown"),
144+
.product(name: "SymbolKit", package: "swift-docc-symbolkit"),
145+
],
146+
exclude: ["CMakeLists.txt"],
147+
swiftSettings: [.swiftLanguageMode(.v6)]
148+
),
149+
.testTarget(
150+
name: "DocCHTMLTests",
151+
dependencies: [
152+
.target(name: "DocCHTML"),
153+
.target(name: "SwiftDocC"),
154+
.product(name: "Markdown", package: "swift-markdown"),
155+
.target(name: "SwiftDocCTestUtilities"),
156+
],
157+
swiftSettings: [.swiftLanguageMode(.v6)]
158+
),
112159

113160
// Test app for SwiftDocCUtilities
114161
.executableTarget(

Sources/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Licensed under Apache License v2.0 with Runtime Library Exception
77
See https://swift.org/LICENSE.txt for license information
88
#]]
99

10+
add_subdirectory(DocCCommon)
1011
add_subdirectory(SwiftDocC)
1112
add_subdirectory(SwiftDocCUtilities)
1213
add_subdirectory(docc)

Sources/DocCCommon/CMakeLists.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#[[
2+
This source file is part of the Swift open source project
3+
4+
Copyright © 2014 - 2025 Apple Inc. and the Swift project authors
5+
Licensed under Apache License v2.0 with Runtime Library Exception
6+
7+
See https://swift.org/LICENSE.txt for license information
8+
#]]
9+
10+
add_library(DocCCommon STATIC
11+
FixedSizeBitSet.swift
12+
Mutex.swift
13+
SourceLanguage.swift)

0 commit comments

Comments
 (0)