File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,20 @@ struct GlobalActor {
9393func testGlobalActor( ) async {
9494}
9595
96+ // CHECK-LABEL: sil hidden [ossa] @$s4test0A17GlobalActorUnsafeyyYaF : $@convention(thin) @async () -> () {
97+ // CHECK: [[F:%[0-9]+]] = function_ref @$s4test11GlobalActorV6sharedAA02MyC0Cvau : $@convention(thin) () -> Builtin.RawPointer
98+ // CHECK: [[P:%[0-9]+]] = apply [[F]]() : $@convention(thin) () -> Builtin.RawPointer
99+ // CHECK: [[A:%[0-9]+]] = pointer_to_address %2 : $Builtin.RawPointer to [strict] $*MyActor
100+ // CHECK: [[ACC:%[0-9]+]] = begin_access [read] [dynamic] [[A]] : $*MyActor
101+ // CHECK: [[L:%[0-9]+]] = load [copy] [[ACC]] : $*MyActor
102+ // CHECK: [[B:%[0-9]+]] = begin_borrow [[L]] : $MyActor
103+ // CHECK: hop_to_executor [[B]] : $MyActor
104+ // CHECK: }
105+ @GlobalActor
106+ @_predatesConcurrency
107+ func testGlobalActorUnsafe( ) async {
108+ }
109+
96110///// testGlobalActorWithClosure()
97111// CHECK: sil hidden [ossa] @$s4test0A22GlobalActorWithClosureyyYaF : $@convention(thin) @async () -> () {
98112// CHECK: hop_to_executor [[A:%[0-9]+]] : $MyActor
You can’t perform that action at this time.
0 commit comments