// RUN: %target-run-simple-swift(-parse-as-library -Xfrontend -enable-experimental-concurrency %import-libdispatch) | %FileCheck %s // REQUIRES: executable_test // REQUIRES: concurrency // REQUIRES: libdispatch // rdar://76038845 // UNSUPPORTED: use_os_stdlib // UNSUPPORTED: back_deployment_runtime // for sleep #if canImport(Darwin) import Darwin #elseif canImport(Glibc) import Glibc #endif @available(SwiftStdlib 5.5, *) class Runner { func run() async { while !Task.isCancelled { sleep(1) } } } @available(SwiftStdlib 5.5, *) actor Container { var generation = 0 var runners = [Int : Task.Handle]() func build(_ n: Int) { for _ in 0..