10
10
//
11
11
//===----------------------------------------------------------------------===//
12
12
13
- /// The build configuration such as debug or release.
13
+ /// The build configuration, such as debug or release.
14
14
public struct BuildConfiguration {
15
+ /// The configuration of the build. Valid values are `debug` and `release`.
15
16
let config : String
16
17
17
18
private init ( _ config: String ) {
@@ -54,7 +55,9 @@ public struct BuildConfiguration {
54
55
/// ),
55
56
/// ```
56
57
public struct BuildSettingCondition {
58
+ /// The applicable platforms for this build setting condition.
57
59
let platforms : [ Platform ] ?
60
+ /// The applicable build configuration for this build setting condition.
58
61
let config : BuildConfiguration ?
59
62
60
63
private init ( platforms: [ Platform ] ? , config: BuildConfiguration ? ) {
@@ -111,8 +114,9 @@ struct BuildSettingData {
111
114
let condition : BuildSettingCondition ?
112
115
}
113
116
114
- /// A C- language build setting.
117
+ /// A C language build setting.
115
118
public struct CSetting {
119
+ /// The abstract build setting data.
116
120
let data : BuildSettingData
117
121
118
122
private init ( name: String , value: [ String ] , condition: BuildSettingCondition ? ) {
@@ -131,7 +135,7 @@ public struct CSetting {
131
135
///
132
136
/// - Parameters:
133
137
/// - path: The path of the directory that contains the headers. The path is relative to the target's directory.
134
- /// - condition: A condition that restricts the application of the build setting.
138
+ /// - condition: A condition that restricts the use of the build setting.
135
139
@available ( _PackageDescription, introduced: 5.0 )
136
140
public static func headerSearchPath( _ path: String , _ condition: BuildSettingCondition ? = nil ) -> CSetting {
137
141
return CSetting ( name: " headerSearchPath " , value: [ path] , condition: condition)
@@ -146,7 +150,7 @@ public struct CSetting {
146
150
/// - Parameters:
147
151
/// - name: The name of the macro.
148
152
/// - value: The value of the macro.
149
- /// - condition: A condition that restricts the application of the build
153
+ /// - condition: A condition that restricts the use of the build
150
154
/// setting.
151
155
@available ( _PackageDescription, introduced: 5.0 )
152
156
public static func define( _ name: String , to value: String ? = nil , _ condition: BuildSettingCondition ? = nil ) -> CSetting {
@@ -182,6 +186,7 @@ public struct CSetting {
182
186
183
187
/// A CXX-language build setting.
184
188
public struct CXXSetting {
189
+ /// The data store for the CXX build setting.
185
190
let data : BuildSettingData
186
191
187
192
private init ( name: String , value: [ String ] , condition: BuildSettingCondition ? ) {
@@ -200,6 +205,7 @@ public struct CXXSetting {
200
205
///
201
206
/// - Parameters:
202
207
/// - path: The path of the directory that contains the headers. The path is
208
+ /// relative to the target's directory.
203
209
/// - condition: A condition that restricts the application of the build setting.
204
210
@available ( _PackageDescription, introduced: 5.0 )
205
211
public static func headerSearchPath( _ path: String , _ condition: BuildSettingCondition ? = nil ) -> CXXSetting {
@@ -250,6 +256,7 @@ public struct CXXSetting {
250
256
251
257
/// A Swift language build setting.
252
258
public struct SwiftSetting {
259
+ /// The data store for the Swift build setting.
253
260
let data : BuildSettingData
254
261
255
262
private init ( name: String , value: [ String ] , condition: BuildSettingCondition ? ) {
@@ -306,18 +313,18 @@ public struct SwiftSetting {
306
313
307
314
/// Enable an upcoming feature with the given name.
308
315
///
309
- /// An upcoming feature is one that has been accepted into Swift as of a
310
- /// certain language version, but is not available by default in prior
316
+ /// An upcoming feature is one that is available in Swift as of a
317
+ /// certain language version, but isn't available by default in prior
311
318
/// language modes because it has some impact on source compatibility.
312
319
///
313
- /// Multiple upcoming features can be added to a given target, and can
314
- /// be used in a target without affecting its dependencies. An unknown
315
- /// upcoming feature will be ignored by the implementation .
320
+ /// You can add and use multiple upcoming features in a given target
321
+ /// without affecting its dependencies. Targets will ignore any unknown
322
+ /// upcoming features .
316
323
///
317
324
/// - Since: First available in PackageDescription 5.8.
318
325
///
319
326
/// - Parameters:
320
- /// - name: The name of the upcoming feature, e.g., ConciseMagicFile.
327
+ /// - name: The name of the upcoming feature; for example, ` ConciseMagicFile` .
321
328
/// - condition: A condition that restricts the application of the build
322
329
/// setting.
323
330
@available ( _PackageDescription, introduced: 5.8 )
@@ -331,17 +338,17 @@ public struct SwiftSetting {
331
338
332
339
/// Enable an experimental feature with the given name.
333
340
///
334
- /// An experimental feature is one that is in development, but
335
- /// has not been accepted into Swift as a language feature.
341
+ /// An experimental feature is one that's in development, but
342
+ /// is not yet available in Swift as a language feature.
336
343
///
337
- /// Multiple experimental features can be added to a given target, and can
338
- /// be used in a target without affecting its dependencies. An unknown
339
- /// experimental feature will be ignored by the implementation .
344
+ /// You can add and use multiple experimental features in a given target
345
+ /// without affecting its dependencies. Targets will ignore any unknown
346
+ /// experimental features .
340
347
///
341
348
/// - Since: First available in PackageDescription 5.8.
342
349
///
343
350
/// - Parameters:
344
- /// - name: The name of the experimental feature, e.g., VariadicGenerics.
351
+ /// - name: The name of the experimental feature; for example, ` VariadicGenerics` .
345
352
/// - condition: A condition that restricts the application of the build
346
353
/// setting.
347
354
@available ( _PackageDescription, introduced: 5.8 )
@@ -360,18 +367,18 @@ public struct SwiftSetting {
360
367
361
368
/// Enable Swift interoperability with a given language.
362
369
///
363
- /// This is useful for enabling Swift/ C++ interoperability for a given
370
+ /// This is useful for enabling interoperability with Swift and C++ for a given
364
371
/// target.
365
372
///
366
373
/// Enabling C++ interoperability mode might alter the way some existing
367
- /// C/ Objective-C APIs are imported.
374
+ /// C and Objective-C APIs are imported.
368
375
///
369
376
/// - Since: First available in PackageDescription 5.9.
370
377
///
371
378
/// - Parameters:
372
- /// - mode: The language mode, either C or Cxx .
373
- /// - version: If Cxx language mode is used, the version of Swift/ C++
374
- /// interoperability, otherwise `nil`.
379
+ /// - mode: The language mode, either C or CXX .
380
+ /// - version: When using the CXX language mode, pass the version of Swift and C++
381
+ /// interoperability; otherwise, `nil`.
375
382
/// - condition: A condition that restricts the application of the build
376
383
/// setting.
377
384
@available ( _PackageDescription, introduced: 5.9 )
@@ -391,6 +398,7 @@ public struct SwiftSetting {
391
398
392
399
/// A linker build setting.
393
400
public struct LinkerSetting {
401
+ /// The data store for the Linker setting.
394
402
let data : BuildSettingData
395
403
396
404
private init ( name: String , value: [ String ] , condition: BuildSettingCondition ? ) {
0 commit comments