|
3 | 3 | // RUN: %target-swift-frontend -emit-module -emit-module-path %t/other_global_actor_inference.swiftmodule -module-name other_global_actor_inference -strict-concurrency=complete %S/Inputs/other_global_actor_inference.swift |
4 | 4 | // RUN: %target-swift-frontend -I %t -disable-availability-checking %s -emit-sil -o /dev/null -verify -verify-additional-prefix minimal-targeted- |
5 | 5 | // RUN: %target-swift-frontend -I %t -disable-availability-checking %s -emit-sil -o /dev/null -verify -strict-concurrency=targeted -verify-additional-prefix minimal-targeted- |
6 | | -// RUN: %target-swift-frontend -I %t -disable-availability-checking %s -emit-sil -o /dev/null -verify -strict-concurrency=complete -verify-additional-prefix complete-tns- |
7 | | -// RUN: %target-swift-frontend -I %t -disable-availability-checking %s -emit-sil -o /dev/null -verify -strict-concurrency=complete -enable-experimental-feature SendNonSendable -verify-additional-prefix complete-tns- |
| 6 | +// RUN: %target-swift-frontend -I %t -disable-availability-checking %s -emit-sil -o /dev/null -verify -strict-concurrency=complete -verify-additional-prefix complete-sns- |
8 | 7 |
|
9 | 8 | // REQUIRES: concurrency |
10 | 9 | // REQUIRES: asserts |
@@ -445,7 +444,7 @@ actor ActorWithWrapper { |
445 | 444 | @WrapperOnActor var synced: Int = 0 |
446 | 445 | // expected-note@-1 3{{property declared here}} |
447 | 446 | @WrapperWithMainActorDefaultInit var property: Int // expected-minimal-targeted-error {{call to main actor-isolated initializer 'init()' in a synchronous actor-isolated context}} |
448 | | - // expected-complete-tns-error@-1 {{main actor-isolated default value in a actor-isolated context}} |
| 447 | + // expected-complete-sns-error@-1 {{main actor-isolated default value in a actor-isolated context}} |
449 | 448 | func f() { |
450 | 449 | _ = synced // expected-error{{main actor-isolated property 'synced' can not be referenced on a different actor instance}} |
451 | 450 | _ = $synced // expected-error{{global actor 'SomeGlobalActor'-isolated property '$synced' can not be referenced on a different actor instance}} |
@@ -561,7 +560,7 @@ struct WrapperOnUnsafeActor<Wrapped> { |
561 | 560 |
|
562 | 561 | // HasWrapperOnUnsafeActor gets an inferred @MainActor attribute. |
563 | 562 | struct HasWrapperOnUnsafeActor { |
564 | | - @WrapperOnUnsafeActor var synced: Int = 0 // expected-complete-tns-error {{global actor 'OtherGlobalActor'-isolated default value in a main actor-isolated context}} |
| 563 | + @WrapperOnUnsafeActor var synced: Int = 0 // expected-complete-sns-error {{global actor 'OtherGlobalActor'-isolated default value in a main actor-isolated context}} |
565 | 564 | // expected-note @-1 3{{property declared here}} |
566 | 565 | // expected-complete-sns-note @-2 3{{property declared here}} |
567 | 566 |
|
@@ -647,7 +646,7 @@ func acceptAsyncSendableClosureInheriting<T>(@_inheritActorContext _: @Sendable |
647 | 646 | // defer bodies inherit global actor-ness |
648 | 647 | @MainActor |
649 | 648 | var statefulThingy: Bool = false // expected-minimal-targeted-note {{var declared here}} |
650 | | -// expected-complete-tns-error @-1 {{top-level code variables cannot have a global actor}} |
| 649 | +// expected-complete-sns-error @-1 {{top-level code variables cannot have a global actor}} |
651 | 650 |
|
652 | 651 | @MainActor |
653 | 652 | func useFooInADefer() -> String { // expected-minimal-targeted-note {{calls to global function 'useFooInADefer()' from outside of its actor context are implicitly asynchronous}} |
@@ -681,10 +680,10 @@ class Cutter { |
681 | 680 | @SomeGlobalActor |
682 | 681 | class Butter { |
683 | 682 | var a = useFooInADefer() // expected-minimal-targeted-error {{call to main actor-isolated global function 'useFooInADefer()' in a synchronous global actor 'SomeGlobalActor'-isolated context}} |
684 | | - // expected-complete-tns-error@-1 {{main actor-isolated default value in a global actor 'SomeGlobalActor'-isolated context}} |
| 683 | + // expected-complete-sns-error@-1 {{main actor-isolated default value in a global actor 'SomeGlobalActor'-isolated context}} |
685 | 684 |
|
686 | 685 | nonisolated let b = statefulThingy // expected-minimal-targeted-error {{main actor-isolated var 'statefulThingy' can not be referenced from a non-isolated context}} |
687 | | - // expected-complete-tns-error@-1 {{main actor-isolated default value in a nonisolated context}} |
| 686 | + // expected-complete-sns-error@-1 {{main actor-isolated default value in a nonisolated context}} |
688 | 687 |
|
689 | 688 | var c: Int = { |
690 | 689 | return getGlobal7() |
|
0 commit comments