mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Use the implicit conversion of a closure to an actor isolated closure to trigger the assertion failure. This allows us to test this more broadly on all platforms with concurrency.
12 lines
393 B
Swift
12 lines
393 B
Swift
// RUN: %target-swift-ide-test -print-indexed-symbols -source-filename %s | %FileCheck %s
|
|
// REQUIRES: concurrency
|
|
|
|
@MainActor
|
|
public struct S {
|
|
public init(_: @escaping () -> Void) { }
|
|
}
|
|
|
|
let s = S { }
|
|
// CHECK: [[@LINE-1]]:9 | struct/Swift | S | s:14swift_ide_test1SV | Ref,RelCont
|
|
// CHECK: [[@LINE-2]]:9 | constructor/Swift | init(_:) | s:14swift_ide_test1SVyACyyccfc | Ref,Call,RelCont
|