A block is just a closure, for example, you have it in python or in functional languages. They do not "run along the stream"; they run where they are called.
int main(void) { void (^f)(void) { printf("hello world!\n"); } f(); return 0; }
Does what you think it does, there are no send queues, no threads, nothing.
Although, when you have blocks with all their good capture semantics, it is very tempting to have APIs to plan their execution everywhere. But basically a block is the same as a function pointer, and an ad-hoc structure containing the entire captured variable passed as an argument to the callback (it is even implemented in the compiler).
user1775617
source share