File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
stdlib/public/Concurrency Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -1274,6 +1274,13 @@ static NonDefaultDistributedActorImpl *asImpl(NonDefaultDistributedActor *actor)
12741274/* ******************* NEW DEFAULT ACTOR IMPLEMENTATION ***********************/
12751275/* ****************************************************************************/
12761276
1277+ TaskExecutorRef TaskExecutorRef::fromTaskExecutorPreference (Job *job) {
1278+ if (auto task = dyn_cast<AsyncTask>(job)) {
1279+ return task->getPreferredTaskExecutor ();
1280+ }
1281+ return TaskExecutorRef::undefined ();
1282+ }
1283+
12771284#if !SWIFT_CONCURRENCY_ACTORS_AS_LOCKS
12781285
12791286static void traceJobQueue (DefaultActorImpl *actor, Job *first) {
@@ -1320,13 +1327,6 @@ void DefaultActorImpl::scheduleActorProcessJob(
13201327 swift_task_enqueueGlobal (job);
13211328}
13221329
1323- TaskExecutorRef TaskExecutorRef::fromTaskExecutorPreference (Job *job) {
1324- if (auto task = dyn_cast<AsyncTask>(job)) {
1325- return task->getPreferredTaskExecutor ();
1326- }
1327- return TaskExecutorRef::undefined ();
1328- }
1329-
13301330void DefaultActorImpl::enqueue (Job *job, JobPriority priority) {
13311331 // We can do relaxed loads here, we are just using the current head in the
13321332 // atomic state and linking that into the new job we are inserting, we don't
You can’t perform that action at this time.
0 commit comments