mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
17 lines
387 B
Swift
17 lines
387 B
Swift
// RUN: %target-swift-frontend -typecheck -verify -disable-availability-checking %s -strict-concurrency=complete
|
|
|
|
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()
|
|
}
|
|
}
|
|
}
|