@@ -14,11 +14,13 @@ public import SWBUtil
14
14
15
15
// MARK: Support types
16
16
17
- public struct ConfiguredTargetGUID : Hashable , Sendable , Codable {
18
- public var rawValue : String
17
+ public struct ConfiguredTargetIdentifier : Hashable , Sendable , Codable {
18
+ public var rawGUID : String
19
+ public var targetGUID : TargetGUID
19
20
20
- public init ( _ rawValue: String ) {
21
- self . rawValue = rawValue
21
+ public init ( rawGUID: String , targetGUID: TargetGUID ) {
22
+ self . rawGUID = rawGUID
23
+ self . targetGUID = targetGUID
22
24
}
23
25
}
24
26
@@ -61,25 +63,21 @@ public struct BuildDescriptionConfiguredTargetsResponse: Message, SerializableCo
61
63
62
64
public struct ConfiguredTargetInfo : SerializableCodable , Equatable , Sendable {
63
65
/// The GUID of this configured target
64
- public let guid : ConfiguredTargetGUID
65
-
66
- /// The GUID of the target from which this configured target was created
67
- public let target : TargetGUID
66
+ public let identifier : ConfiguredTargetIdentifier
68
67
69
68
/// A name of the target that may be displayed to the user
70
69
public let name : String
71
70
72
71
/// The configured targets that this target depends on
73
- public let dependencies : Set < ConfiguredTargetGUID >
72
+ public let dependencies : Set < ConfiguredTargetIdentifier >
74
73
75
74
/// The path of the toolchain that should be used to build this target.
76
75
///
77
76
/// `nil` if the toolchain for this target could not be determined due to an error.
78
77
public let toolchain : Path ?
79
78
80
- public init ( guid: ConfiguredTargetGUID , target: TargetGUID , name: String , dependencies: Set < ConfiguredTargetGUID > , toolchain: Path ? ) {
81
- self . guid = guid
82
- self . target = target
79
+ public init ( identifier: ConfiguredTargetIdentifier , name: String , dependencies: Set < ConfiguredTargetIdentifier > , toolchain: Path ? ) {
80
+ self . identifier = identifier
83
81
self . name = name
84
82
self . dependencies = dependencies
85
83
self . toolchain = toolchain
@@ -108,9 +106,9 @@ public struct BuildDescriptionConfiguredTargetSourcesRequest: SessionMessage, Re
108
106
public let request : BuildRequestMessagePayload
109
107
110
108
/// The configured targets for which to load source file information
111
- public let configuredTargets : [ ConfiguredTargetGUID ]
109
+ public let configuredTargets : [ ConfiguredTargetIdentifier ]
112
110
113
- public init ( sessionHandle: String , buildDescriptionID: BuildDescriptionID , request: BuildRequestMessagePayload , configuredTargets: [ ConfiguredTargetGUID ] ) {
111
+ public init ( sessionHandle: String , buildDescriptionID: BuildDescriptionID , request: BuildRequestMessagePayload , configuredTargets: [ ConfiguredTargetIdentifier ] ) {
114
112
self . sessionHandle = sessionHandle
115
113
self . buildDescriptionID = buildDescriptionID
116
114
self . request = request
@@ -148,12 +146,12 @@ public struct BuildDescriptionConfiguredTargetSourcesResponse: Message, Serializ
148
146
149
147
public struct ConfiguredTargetSourceFilesInfo : SerializableCodable , Equatable , Sendable {
150
148
/// The configured target to which this info belongs
151
- public let configuredTarget : ConfiguredTargetGUID
149
+ public let configuredTarget : ConfiguredTargetIdentifier
152
150
153
151
/// Information about the source files in this source file
154
152
public let sourceFiles : [ SourceFileInfo ]
155
153
156
- public init ( configuredTarget: ConfiguredTargetGUID , sourceFiles: [ SourceFileInfo ] ) {
154
+ public init ( configuredTarget: ConfiguredTargetIdentifier , sourceFiles: [ SourceFileInfo ] ) {
157
155
self . configuredTarget = configuredTarget
158
156
self . sourceFiles = sourceFiles
159
157
}
@@ -182,7 +180,7 @@ public struct IndexBuildSettingsRequest: SessionMessage, RequestMessage, Seriali
182
180
public let request : BuildRequestMessagePayload
183
181
184
182
/// The configured target in whose context the build settings of the source file should be loaded
185
- public let configuredTarget : ConfiguredTargetGUID
183
+ public let configuredTarget : ConfiguredTargetIdentifier
186
184
187
185
/// The path of the source file for which the build settings should be loaded
188
186
public let file : Path
@@ -191,7 +189,7 @@ public struct IndexBuildSettingsRequest: SessionMessage, RequestMessage, Seriali
191
189
sessionHandle: String ,
192
190
buildDescriptionID: BuildDescriptionID ,
193
191
request: BuildRequestMessagePayload ,
194
- configuredTarget: ConfiguredTargetGUID ,
192
+ configuredTarget: ConfiguredTargetIdentifier ,
195
193
file: Path
196
194
) {
197
195
self . sessionHandle = sessionHandle
0 commit comments