@@ -192,10 +192,10 @@ public struct TestInStruct {
192
192
193
193
// CHECK-LABEL: #if compiler(>=5.3) && $SendingArgsAndResults
194
194
// CHECK-NEXT: @usableFromInline
195
- // CHECK-NEXT: internal init(_ x: Int, transformWithResult: @escaping () async throws -> sending test.NonSendableKlass) { fatalError() }
195
+ // CHECK-NEXT: internal init(_ x: Swift. Int, transformWithResult: @escaping () async throws -> sending test.NonSendableKlass)
196
196
// CHECK-NEXT: #else
197
197
// CHECK-NEXT: @usableFromInline
198
- // CHECK-NEXT: internal init(_ x: Int, transformWithResult: @escaping () async throws -> test.NonSendableKlass) { fatalError() }
198
+ // CHECK-NEXT: internal init(_ x: Swift. Int, transformWithResult: @escaping () async throws -> test.NonSendableKlass)
199
199
// CHECK-NEXT: #endif
200
200
@usableFromInline
201
201
internal init ( _ x: Int , transformWithResult: @escaping ( ) async throws -> sending NonSendableKlass) { fatalError ( ) }
@@ -204,19 +204,38 @@ public struct TestInStruct {
204
204
// Make sure that we emit compiler(>= 5.3) when emitting the suppressing check
205
205
// to make sure we do not fail if we fail to parse sending in the if block.
206
206
207
- // CHECK: #if compiler(>=5.3) && $OptionalIsolatedParameters && $ExpressionMacroDefaultArguments
208
- // CHECK-NEXT: #if compiler(>=5.3) && $SendingArgsAndResults
209
- // CHECK-NEXT: @available(macOS 10.15, iOS 13.0, watchOS 6.0, tvOS 13.0, *)
210
- // CHECK-NEXT: @backDeployed(before: macOS 9999, iOS 9999, watchOS 9999, tvOS 9999, visionOS 9999)
211
- // CHECK-NEXT: @inlinable public func withCheckedContinuation<T>(isolation:
212
- @available ( macOS 10 . 15 , iOS 13 . 0 , watchOS 6 . 0 , tvOS 13 . 0 , * )
213
- @backDeployed ( before: macOS 9999 , iOS 9999 , watchOS 9999 , tvOS 9999 , visionOS 9999 )
207
+ // CHECK-LABEL: #if compiler(>=5.3) && $OptionalIsolatedParameters && $ExpressionMacroDefaultArguments // Suppression Count: 24
208
+ // CHECK-NEXT: #if compiler(>=5.3) && $SendingArgsAndResults // Suppression Count: 25
209
+ // CHECK-NEXT: @inlinable public func withCheckedContinuation<T>(isolation: isolated (any _Concurrency.Actor)? = #isolation, function: Swift.String = #function, _ body: (_Concurrency.CheckedContinuation<T, Swift.Never>) -> Swift.Void) async -> sending T {
210
+ // CHECK-NEXT: fatalError()
211
+ // CHECK-NEXT: }
212
+ // CHECK-NEXT: #else
213
+ // CHECK-NEXT: @inlinable public func withCheckedContinuation<T>(isolation: isolated (any _Concurrency.Actor)? = #isolation, function: Swift.String = #function, _ body: (_Concurrency.CheckedContinuation<T, Swift.Never>) -> Swift.Void) async -> T {
214
+ // CHECK-NEXT: fatalError()
215
+ // CHECK-NEXT: }
216
+ // CHECK-NEXT: #endif
217
+ // CHECK-NEXT: #endif
214
218
@inlinable public func withCheckedContinuation< T> (
215
219
isolation: isolated ( any _Concurrency . Actor ) ? = #isolation,
216
220
function: String = #function,
217
221
_ body: ( _Concurrency . CheckedContinuation < T , Swift . Never > ) -> Swift . Void
218
222
) async -> sending T {
219
- return await withUnsafeContinuation {
220
- body ( CheckedContinuation ( continuation: $0, function: function) )
221
- }
223
+ fatalError ( )
222
224
}
225
+
226
+ // CHECK-LABEL: #if compiler(>=5.3) && $SendingArgsAndResults // Suppression Count: 26
227
+ // CHECK-NEXT: public var publicGlobal: (sending test.NonSendableKlass) -> ()
228
+ // CHECK-NEXT: #else
229
+ // CHECK-NEXT: public var publicGlobal: (test.NonSendableKlass) -> ()
230
+ // CHECK-NEXT: #endif
231
+ public var publicGlobal : ( sending NonSendableKlass) -> ( ) = { x in fatalError ( ) }
232
+
233
+ // CHECK-LABEL: #if compiler(>=5.3) && $SendingArgsAndResults // Suppression Count: 27
234
+ // CHECK-NEXT: @usableFromInline
235
+ // CHECK-NEXT: internal var usableFromInlineGlobal: (sending test.NonSendableKlass) -> ()
236
+ // CHECK-NEXT: #else
237
+ // CHECK-NEXT: @usableFromInline
238
+ // CHECK-NEXT: internal var usableFromInlineGlobal: (test.NonSendableKlass) -> ()
239
+ // CHECK-NEXT: #endif
240
+ @usableFromInline
241
+ internal var usableFromInlineGlobal : ( sending NonSendableKlass) -> ( ) = { x in fatalError ( ) }
0 commit comments