Skip to content

Commit 931d16c

Browse files
committed
[Concurrency] Rename IsolatedDefaultArguments to IsolatedDefaultValues.
(cherry picked from commit 5a81c00)
1 parent 5c56541 commit 931d16c

File tree

7 files changed

+11
-11
lines changed

7 files changed

+11
-11
lines changed

include/swift/Basic/Features.def

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,8 +222,8 @@ EXPERIMENTAL_FEATURE(SendNonSendable, false)
222222
/// Within strict concurrency, narrow global variable isolation requirements.
223223
EXPERIMENTAL_FEATURE(GlobalConcurrency, false)
224224

225-
/// Allow default arguments to require isolation at the call-site.
226-
EXPERIMENTAL_FEATURE(IsolatedDefaultArguments, false)
225+
/// Allow default values to require isolation at the call-site.
226+
EXPERIMENTAL_FEATURE(IsolatedDefaultValues, false)
227227

228228
/// Enable extended callbacks (with additional parameters) to be used when the
229229
/// "playground transform" is enabled.

lib/AST/ASTPrinter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3502,7 +3502,7 @@ static bool usesFeatureSendNonSendable(Decl *decl) {
35023502

35033503
static bool usesFeatureGlobalConcurrency(Decl *decl) { return false; }
35043504

3505-
static bool usesFeatureIsolatedDefaultArguments(Decl *decl) {
3505+
static bool usesFeatureIsolatedDefaultValues(Decl *decl) {
35063506
return false;
35073507
}
35083508

lib/AST/Decl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10293,7 +10293,7 @@ ActorIsolation swift::getActorIsolationOfContext(
1029310293
// that meet the required isolation.
1029410294
if (auto *var = dcToUse->getNonLocalVarDecl()) {
1029510295
auto &ctx = dc->getASTContext();
10296-
if (ctx.LangOpts.hasFeature(Feature::IsolatedDefaultArguments) &&
10296+
if (ctx.LangOpts.hasFeature(Feature::IsolatedDefaultValues) &&
1029710297
var->isInstanceMember() &&
1029810298
!var->getAttrs().hasAttribute<LazyAttr>()) {
1029910299
return ActorIsolation::forNonisolated();

lib/Sema/TypeCheckConcurrency.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2294,7 +2294,7 @@ namespace {
22942294
ActorIsolation computeRequiredIsolation(Expr *expr) {
22952295
auto &ctx = getDeclContext()->getASTContext();
22962296

2297-
if (ctx.LangOpts.hasFeature(Feature::IsolatedDefaultArguments))
2297+
if (ctx.LangOpts.hasFeature(Feature::IsolatedDefaultValues))
22982298
requiredIsolationLoc = expr->getLoc();
22992299

23002300
expr->walk(*this);

test/Concurrency/isolated_default_arguments.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
// RUN: %target-swift-frontend -emit-module -emit-module-path %t/OtherActors.swiftmodule -module-name OtherActors %S/Inputs/OtherActors.swift -disable-availability-checking
44

5-
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -enable-experimental-feature IsolatedDefaultArguments -parse-as-library -emit-sil -o /dev/null -verify %s
6-
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -parse-as-library -emit-sil -o /dev/null -verify -enable-experimental-feature IsolatedDefaultArguments -enable-experimental-feature SendNonSendable %s
5+
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -enable-experimental-feature IsolatedDefaultValues -parse-as-library -emit-sil -o /dev/null -verify %s
6+
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -parse-as-library -emit-sil -o /dev/null -verify -enable-experimental-feature IsolatedDefaultValues -enable-experimental-feature SendNonSendable %s
77

88
// REQUIRES: concurrency
99
// REQUIRES: asserts

test/Concurrency/isolated_default_arguments_serialized.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// RUN: %empty-directory(%t)
2-
// RUN: %target-swift-frontend -emit-module -swift-version 5 -emit-module-path %t/SerializedDefaultArguments.swiftmodule -module-name SerializedDefaultArguments -enable-experimental-feature IsolatedDefaultArguments %S/Inputs/serialized_default_arguments.swift
2+
// RUN: %target-swift-frontend -emit-module -swift-version 5 -emit-module-path %t/SerializedDefaultArguments.swiftmodule -module-name SerializedDefaultArguments -enable-experimental-feature IsolatedDefaultValues %S/Inputs/serialized_default_arguments.swift
33

44
// RUN: %target-swift-frontend %s -emit-sil -o /dev/null -verify -disable-availability-checking -swift-version 6 -I %t
5-
// RUN: %target-swift-frontend %s -emit-sil -o /dev/null -verify -disable-availability-checking -swift-version 6 -I %t -enable-experimental-feature SendNonSendable -enable-experimental-feature IsolatedDefaultArguments
5+
// RUN: %target-swift-frontend %s -emit-sil -o /dev/null -verify -disable-availability-checking -swift-version 6 -I %t -enable-experimental-feature SendNonSendable -enable-experimental-feature IsolatedDefaultValues
66

77
// REQUIRES: concurrency
88
// REQUIRES: asserts

test/Concurrency/isolated_default_property_inits.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
// RUN: %target-swift-frontend -emit-module -emit-module-path %t/OtherActors.swiftmodule -module-name OtherActors %S/Inputs/OtherActors.swift -disable-availability-checking
44

5-
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -enable-experimental-feature IsolatedDefaultArguments -parse-as-library -emit-sil -o /dev/null -verify %s
6-
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -parse-as-library -emit-sil -o /dev/null -verify -enable-experimental-feature IsolatedDefaultArguments -enable-experimental-feature SendNonSendable %s
5+
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -enable-experimental-feature IsolatedDefaultValues -parse-as-library -emit-sil -o /dev/null -verify %s
6+
// RUN: %target-swift-frontend -I %t -disable-availability-checking -strict-concurrency=complete -parse-as-library -emit-sil -o /dev/null -verify -enable-experimental-feature IsolatedDefaultValues -enable-experimental-feature SendNonSendable %s
77

88
// REQUIRES: concurrency
99
// REQUIRES: asserts

0 commit comments

Comments
 (0)