@@ -17,6 +17,10 @@ struct MyStruct {
17
17
@_section ( " __TEXT,__mysection " ) @_used func foo( ) { }
18
18
}
19
19
20
+ @_section ( " __TEXT,__mysection " )
21
+ var functionptr = testit
22
+ func testit( _ e: consuming Any ) -> Any { e }
23
+
20
24
// SIL: @_section("__DATA,__mysection") @_hasStorage @_hasInitialValue var g0: Int { get set }
21
25
// SIL: @_section("__DATA,__mysection") @_hasStorage @_hasInitialValue var g1: (Int, Int) { get set }
22
26
// SIL: @_section("__DATA,__mysection") @_hasStorage @_hasInitialValue var g2: Bool { get set }
@@ -28,22 +32,23 @@ struct MyStruct {
28
32
// SIL: @_section("__DATA,__mysection") @_hasStorage @_hasInitialValue static var static0: Int { get set }
29
33
// SIL: @_section("__TEXT,__mysection") @_used func foo()
30
34
31
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g0_WZ : $@convention(c)
35
+ // SIL: sil private [global_init_once_fn] @$s7section2g0_WZ : $@convention(c)
32
36
// SIL: sil hidden [global_init] @$s7section2g0Sivau : $@convention(thin)
33
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g1_WZ : $@convention(c)
37
+ // SIL: sil private [global_init_once_fn] @$s7section2g1_WZ : $@convention(c)
34
38
// SIL: sil hidden [global_init] @$s7section2g1Si_Sitvau : $@convention(thin)
35
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g2_WZ : $@convention(c)
39
+ // SIL: sil private [global_init_once_fn] @$s7section2g2_WZ : $@convention(c)
36
40
// SIL: sil hidden [global_init] @$s7section2g2Sbvau : $@convention(thin)
37
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g3_WZ : $@convention(c)
41
+ // SIL: sil private [global_init_once_fn] @$s7section2g3_WZ : $@convention(c)
38
42
// SIL: sil [global_init] @$s7section2g3Sbvau : $@convention(thin)
39
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g4_WZ : $@convention(c)
43
+ // SIL: sil private [global_init_once_fn] @$s7section2g4_WZ : $@convention(c)
40
44
// SIL: sil hidden [global_init] @$s7section2g4SpySiGSgvau : $@convention(thin)
41
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section2g5_WZ : $@convention(c)
45
+ // SIL: sil private [global_init_once_fn] @$s7section2g5_WZ : $@convention(c)
42
46
// SIL: sil hidden [global_init] @$s7section2g5SpySiGSgvau : $@convention(thin)
43
47
// SIL: sil hidden [used] [section "__TEXT,__mysection"] @$s7section3fooyyF : $@convention(thin)
44
- // SIL: sil private [global_init_once_fn] [perf_constraint] @$s7section8MyStructV7static0_WZ : $@convention(c)
48
+ // SIL: sil private [global_init_once_fn] @$s7section8MyStructV7static0_WZ : $@convention(c)
45
49
// SIL: sil hidden [global_init] @$s7section8MyStructV7static0Sivau : $@convention(thin)
46
50
// SIL: sil hidden [used] [section "__TEXT,__mysection"] @$s7section8MyStructV3fooyyF : $@convention(method)
51
+ // SIL: sil hidden @$s7section6testityypypnF : $@convention(thin) (@in Any) -> @out Any {
47
52
48
53
// IR: @"$s7section2g0Sivp" = hidden global %TSi <{ {{(i64|i32)}} 1 }>, section "__DATA,__mysection"
49
54
// IR: @"$s7section2g1Si_Sitvp" = hidden global <{ %TSi, %TSi }> <{ %TSi <{ {{(i64|i32)}} 42 }>, %TSi <{ {{(i64|i32)}} 43 }> }>, section "__DATA,__mysection"
0 commit comments