> On First, this is a huge breaking change, and it doesn’t really have to be 
> one. The current SPM convention is to prefix C libraries with Lib. Following 
> this convention, Dispatch (which is the C version) would be renamed to 
> LibDispatch, and this new wrapper library would be called just Dispatch. With 
> this setup, the old C api would still be there (under the module 
> LibDispatch), which makes migration much easier. In the proposal, this issue 
> is not addressed at all and it even says that all code using libdispatch 
> would be affected. As it stands, that is not ok.

Separating existing dispatch from a new SwiftDispatch is a great idea.  It 
would give the opportunity to really spend time working on the right approach 
for concurrency in swift without affecting existing production code and the 
hundreds of dispatch wrappers out there.

While we're on the subject: Dispatch Queues are 'queues' ... Isn't the right 
verb append (for asynchronous dispatch)?

DispatchQueue.main.append {
  print("Hello Swift")
}

After all, asyncDispatch or dispatchAsync imply you are dispatching a 
synchronously - which you are not.  The dispatch (sending for execution) is 
always synchronous, it's the execution which is asynchronous.

DispatchQueue.main.dispatchForAsynchronousExecution {
  print("Help, I have repetitive strain injury")
}

Just my 2¢
Andrew.
_______________________________________________
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to