File tree Expand file tree Collapse file tree 1 file changed +15
-14
lines changed Expand file tree Collapse file tree 1 file changed +15
-14
lines changed Original file line number Diff line number Diff line change 1515import Dispatch
1616
1717final class NaiveQueueExecutor : TaskExecutor {
18- let queue : DispatchQueue
18+ let queue : DispatchQueue
1919
20- init ( _ queue: DispatchQueue ) {
21- self . queue = queue
22- }
20+ init ( _ queue: DispatchQueue ) {
21+ self . queue = queue
22+ }
2323
24- public func enqueue( _ _job: consuming ExecutorJob ) {
25- let job = UnownedJob ( _job)
26- queue. async {
27- job. runSynchronously (
28- on: self . asUnownedTaskExecutor ( ) )
24+ public func enqueue( _ _job: consuming ExecutorJob ) {
25+ let job = UnownedJob ( _job)
26+ queue. async {
27+ job. runSynchronously (
28+ on: self . asUnownedTaskExecutor ( )
29+ )
30+ }
2931 }
30- }
3132
32- @inlinable
33- public func asUnownedTaskExecutor( ) -> UnownedTaskExecutor {
34- UnownedTaskExecutor ( ordinary: self )
35- }
33+ @inlinable
34+ public func asUnownedTaskExecutor( ) -> UnownedTaskExecutor {
35+ UnownedTaskExecutor ( ordinary: self )
36+ }
3637}
You can’t perform that action at this time.
0 commit comments