File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Sources/JavaScriptEventLoop Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -48,14 +48,19 @@ extension JavaScriptEventLoop: SchedulingExecutor {
4848 } else if let _ = clock as? SuspendingClock {
4949 duration = delay as! SuspendingClock . Duration
5050 } else {
51- // Hand-off the scheduling work to Clock implementation for unknown clocks
51+ #if compiler(>=6.4)
52+ // Hand-off the scheduling work to Clock implementation for unknown clocks.
53+ // Clock.enqueue is only available in the development branch (6.4+).
5254 clock. enqueue (
5355 job,
5456 on: self ,
5557 at: clock. now. advanced ( by: delay) ,
5658 tolerance: tolerance
5759 )
5860 return
61+ #else
62+ fatalError ( " Unsupported clock type; only ContinuousClock and SuspendingClock are supported " )
63+ #endif
5964 }
6065 #else
6166 fatalError ( " SchedulingExecutor.enqueue is not supported in embedded mode " )
You can’t perform that action at this time.
0 commit comments