Files
swift-mirror/test/Concurrency/unsafe_inherit_executor_lib.swift
Michael Gottesman b3e837c16c [region-isolation] Enable region isolation by default with strict-concurrency.
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
2024-04-04 13:07:32 -07:00

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()
}
}
}