@@ -489,11 +489,11 @@ namespace {
489489 SGFContext C);
490490
491491 // / Helper method for handling function conversion expr to
492- // / @execution(caller ). Returns an empty RValue on failure.
492+ // / nonisolated(nonsending ). Returns an empty RValue on failure.
493493 RValue emitFunctionCvtToExecutionCaller (FunctionConversionExpr *E,
494494 SGFContext C);
495495 // / Helper method for handling function conversion expr to a global actor
496- // / from an @execution(caller ) function.
496+ // / from an nonisolated(nonsending ) function.
497497 RValue
498498 emitFunctionCvtFromExecutionCallerToGlobalActor (FunctionConversionExpr *E,
499499 SGFContext C);
@@ -1968,17 +1968,17 @@ RValueEmitter::emitFunctionCvtToExecutionCaller(FunctionConversionExpr *e,
19681968 //
19691969 // Swift 6:
19701970 //
1971- // (fn_cvt_expr type="@execution(caller ) () async -> ()"
1972- // (fn_cvt_expr type="@execution(caller ) @Sendable () async -> ()"
1971+ // (fn_cvt_expr type="nonisolated(nonsending ) () async -> ()"
1972+ // (fn_cvt_expr type="nonisolated(nonsending ) @Sendable () async -> ()"
19731973 // (declref_expr type="() async -> ()"
19741974 //
19751975 // Swift 5:
19761976 //
1977- // (fn_cvt_expr type="@execution(caller ) () async -> ()"
1977+ // (fn_cvt_expr type="nonisolated(nonsending ) () async -> ()"
19781978 // (declref_expr type="() async -> ()"
19791979 //
19801980 // The @Sendable in Swift 6 mode is due to us not representing
1981- // @execution(caller ) or @Sendable in the constraint evaluator.
1981+ // nonisolated(nonsending ) or @Sendable in the constraint evaluator.
19821982 //
19831983 // The reason why we need to evaluate this especially is that otherwise we
19841984 // generate multiple
@@ -2038,7 +2038,7 @@ RValue RValueEmitter::emitFunctionCvtFromExecutionCallerToGlobalActor(
20382038 // We are pattern matching a conversion sequence like the following:
20392039 //
20402040 // (fn_cvt_expr implicit type="@GlobalActor @Sendable () async -> ()
2041- // (fn_cvt_expr implicit type="@execution(caller ) @Sendable () async -> ()"
2041+ // (fn_cvt_expr implicit type="nonisolated(nonsending ) @Sendable () async -> ()"
20422042 // (declref_expr type="() async -> ()"
20432043 //
20442044 // Where the declref referred to by the declref_expr has execution(caller)
@@ -2047,9 +2047,9 @@ RValue RValueEmitter::emitFunctionCvtFromExecutionCallerToGlobalActor(
20472047 // fix it up later.
20482048 //
20492049 // What we want to emit first a direct reference to the caller as an
2050- // @execution(caller ) function, then we convert it to @execution(caller )
2051- // @Sendable. Finally, we thunk @execution(caller ) to @GlobalActor. The
2052- // thunking is important so that we can ensure that @execution(caller ) runs on
2050+ // nonisolated(nonsending ) function, then we convert it to nonisolated(nonsending )
2051+ // @Sendable. Finally, we thunk nonisolated(nonsending ) to @GlobalActor. The
2052+ // thunking is important so that we can ensure that nonisolated(nonsending ) runs on
20532053 // that specific @GlobalActor.
20542054
20552055 CanAnyFunctionType destType =
@@ -2201,13 +2201,13 @@ RValue RValueEmitter::visitFunctionConversionExpr(FunctionConversionExpr *e,
22012201 }
22022202 }
22032203
2204- // Check if we are converting a function to an @execution(caller ) from a
2205- // declref that is also @execution(caller ). In such a case, this was a case
2204+ // Check if we are converting a function to an nonisolated(nonsending ) from a
2205+ // declref that is also nonisolated(nonsending ). In such a case, this was a case
22062206 // that was put in by Sema. We do not need a thunk, but just need to recognize
22072207 // this case and elide the conversion. The reason why we need to do this is
2208- // that otherwise, we put in extra thunks that convert @execution(caller ) to
2209- // @execution( concurrent) back to @execution(caller ). This is done b/c we do
2210- // not represent @execution(caller ) in interface types, so the actual decl ref
2208+ // that otherwise, we put in extra thunks that convert nonisolated(nonsending ) to
2209+ // @concurrent back to nonisolated(nonsending ). This is done b/c we do
2210+ // not represent nonisolated(nonsending ) in interface types, so the actual decl ref
22112211 // will be viewed as @async () -> ().
22122212 if (destType->getIsolation ().isNonIsolatedCaller ()) {
22132213 if (RValue rv = emitFunctionCvtToExecutionCaller (e, C))
0 commit comments