You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: stdlib/public/Concurrency/Task.swift
+4-11Lines changed: 4 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -167,24 +167,17 @@ extension Task {
167
167
///
168
168
/// - Returns: The task's result.
169
169
publicvarvalue:Success{
170
+
// FIXME: This seems wrong that abi test is not freaking out here?
171
+
// At the same time, adding a silgen_name compat accessor with old signature results in duplicate definitions -- is mangling of typed throws not done properly on return position?
170
172
get asyncthrows(Failure){
171
173
do{
172
-
returntryawait__abi_value
174
+
returntryawait_taskFutureGetThrowing(_task)
173
175
}catch{
174
176
throw error as!Failure
175
177
}
176
178
}
177
179
}
178
180
179
-
@available(SwiftStdlib 5.1,*)
180
-
@_silgen_name("$sScT5valuexvg")
181
-
@usableFromInline
182
-
internalvar__abi_value:Success{
183
-
get asyncthrows{
184
-
returntryawait_taskFutureGetThrowing(_task)
185
-
}
186
-
}
187
-
188
181
/// The result or error from a throwing task, after it completes.
189
182
///
190
183
/// If the task hasn't completed,
@@ -200,7 +193,7 @@ extension Task {
200
193
publicvarresult:Result<Success,Failure>{
201
194
get async{
202
195
do{
203
-
return.success(tryawait__abi_value)
196
+
return.success(tryawaitvalue)
204
197
}catch{
205
198
return.failure(error as!Failure) // as!-safe, guaranteed to be Failure
0 commit comments