@@ -1845,6 +1845,17 @@ static ValueDecl *getWithUnsafeContinuation(ASTContext &ctx,
18451845 return builder.build (id);
18461846}
18471847
1848+ static ValueDecl *getHopToActor (ASTContext &ctx, Identifier id) {
1849+ BuiltinFunctionBuilder builder (ctx);
1850+ auto *actorProto = ctx.getProtocol (KnownProtocolKind::Actor);
1851+ // Create type parameters and add conformance constraints.
1852+ auto actorParam = makeGenericParam ();
1853+ builder.addParameter (actorParam);
1854+ builder.addConformanceRequirement (actorParam, actorProto);
1855+ builder.setResult (makeConcrete (TupleType::getEmpty (ctx)));
1856+ return builder.build (id);
1857+ }
1858+
18481859// / An array of the overloaded builtin kinds.
18491860static const OverloadedBuiltinKind OverloadedBuiltinKinds[] = {
18501861 OverloadedBuiltinKind::None,
@@ -2826,6 +2837,9 @@ ValueDecl *swift::getBuiltinValueDecl(ASTContext &Context, Identifier Id) {
28262837 case BuiltinValueKind::WithUnsafeThrowingContinuation:
28272838 return getWithUnsafeContinuation (Context, Id, /* throws=*/ true );
28282839
2840+ case BuiltinValueKind::HopToActor:
2841+ return getHopToActor (Context, Id);
2842+
28292843 case BuiltinValueKind::AutoDiffCreateLinearMapContext:
28302844 return getAutoDiffCreateLinearMapContext (Context, Id);
28312845
0 commit comments