Skip to content

Commit 1c852f9

Browse files
committed
Adding @usableFromInline to needed API
getMainExecutor and asyncMainDrainQueue function declarations are needed to compile programs with the asyn-main function. The functions are declared internal, so they don't show up in the swift interface files.
1 parent 1cc4dd4 commit 1c852f9

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

stdlib/public/Concurrency/Task.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -752,10 +752,12 @@ func _enqueueJobGlobal(_ task: Builtin.Job)
752752
func _enqueueJobGlobalWithDelay(_ delay: UInt64, _ task: Builtin.Job)
753753

754754
@available(SwiftStdlib 5.1, *)
755+
@usableFromInline
755756
@_silgen_name("swift_task_asyncMainDrainQueue")
756757
internal func _asyncMainDrainQueue() -> Never
757758

758759
@available(SwiftStdlib 5.1, *)
760+
@usableFromInline
759761
@_silgen_name("swift_task_getMainExecutor")
760762
internal func _getMainExecutor() -> Builtin.Executor
761763

0 commit comments

Comments
 (0)