- Notifications
You must be signed in to change notification settings - Fork 10.5k
/
Copy pathconcurrency.swift
30 lines (20 loc) · 794 Bytes
/
concurrency.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// RUN: %empty-directory(%t)
// RUN: %target-build-swift -emit-executable %s -g -o %t/concurrency -emit-module
// RUN: sed -ne '/\/\/ *DEMANGLE-TYPE: /s/\/\/ *DEMANGLE-TYPE: *//p' < %s > %t/input
// RUN: %lldb-moduleimport-test-with-sdk %t/concurrency -type-from-mangled=%t/input | %FileCheck %s --check-prefix=CHECK-TYPE
// REQUIRES: concurrency
func blackHole(_:Any...){}
publicvarlookAtMeeee:[(Int)async->Void]=[]
func foo(){
do{
letx1=[(Int)async->Void]()
letx2=[(Int)asyncthrows->Void]()
blackHole(x1, x2)
}
}
// DEMANGLE-TYPE: $sSayySiYacG
// CHECK-TYPE: Array<(Int) async -> ()>
// DEMANGLE-TYPE: $sSayySiYaKcG
// CHECK-TYPE: Array<(Int) async throws -> ()>
// DEMANGLE-TYPE: $sIegH_D
// CHECK-TYPE: @async @callee_guaranteed () -> ()