請教多線程 GCD 關(guān)于異步同步與串行相關(guān)的問題
```
dispatch_queue_t queue = dispatch_queue_create("com.serial.com", DISPATCH_QUEUE_SERIAL);
? ? NSLog(@"1-%@",[NSThread currentThread]);
? ? dispatch_async(queue,^ {
? ? ? ? NSLog(@"2-%@",[NSThread currentThread]);
? ? ? ? dispatch_sync(queue,^{
? ? ? ? ? ? NSLog(@"3-%@",[NSThread currentThread]);
? ? ? ? });
? ? ? ? NSLog(@"4-%@",[NSThread currentThread]);
? ? });
? ? NSLog(@"5-%@",[NSThread currentThread]);?
``` ? ?print 152
執(zhí)行到?? ? ? ? dispatch_sync(queue,^{ 就結(jié)束了。