Skip to content

Commit a3738b4

Browse files
committed
[Concurrency] fix async-boxed-arg to include the Sendable in type
1 parent a5ac6f0 commit a3738b4

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/DebugInfo/async-boxed-arg.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
// RUN: %target-swift-frontend %s -emit-ir -g -o - -parse-as-library \
2-
// RUN: -module-name M -enable-experimental-concurrency | %FileCheck %s
2+
// RUN: -module-name M -enable-experimental-concurrency | %FileCheck %s --dump-input always
33
// REQUIRES: concurrency
44

55
@available(macOS 9999, iOS 9999, watchOS 9999, tvOS 9999, *)
6-
extension Collection {
6+
extension Collection where Element: Sendable {
77
public func f() async throws {
8-
return await try withTaskGroup(of: Element.self) { group in
8+
return try await withThrowingTaskGroup(of: Element.self) { group in
99
var i = self.startIndex
1010
func doit() async throws {
1111
group.spawn { [i] in
1212
return self[i]
1313
}
1414
}
15-
await try doit()
15+
try await doit()
1616
}
1717
}
1818
}
1919

20-
// CHECK: ![[BOXTY:[0-9]+]] = !DICompositeType(tag: DW_TAG_structure_type, name: "$s5IndexSlQzz_x_SlRzlXXD"
20+
// CHECK: ![[BOXTY:[0-9]+]] = !DICompositeType(tag: DW_TAG_structure_type, name: "$s5IndexSlQzz_x_SlRzs8Sendable7ElementSTRpzlXXD"
2121
// CHECK: !DILocalVariable(name: "i", arg: 3, {{.*}}type: ![[BOXTY]]

0 commit comments

Comments
 (0)