mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
I added a disable flag -disable-region-based-isolation-with-strict-concurrency so that we do not need to update the current tests. It is only available when asserts are enabled to ensure users cannot use it. rdar://125918028
21 lines
627 B
Swift
21 lines
627 B
Swift
// RUN: %target-swift-frontend -emit-sil -verify -o /dev/null -disable-availability-checking %s -strict-concurrency=complete -disable-region-based-isolation-with-strict-concurrency
|
|
// RUN: %target-swift-frontend -emit-sil -verify -o /dev/null -disable-availability-checking %s -strict-concurrency=complete
|
|
|
|
// REQUIRES: concurrency
|
|
// REQUIRES: asserts
|
|
|
|
actor A {
|
|
func g() { }
|
|
func h() throws { }
|
|
|
|
func f() async throws {
|
|
await withTaskGroup(of: Int.self, returning: Void.self) { group in
|
|
g()
|
|
}
|
|
|
|
try await withThrowingTaskGroup(of: Int.self, returning: Void.self) { group in
|
|
try h()
|
|
}
|
|
}
|
|
}
|