There is a piece of code like
typedef void (^SignIn) (NSString *email, NSString *password);
What does the ^ mean before SignIn? Is this Objective-C specific usage?
There is a piece of code like
typedef void (^SignIn) (NSString *email, NSString *password);
What does the ^ mean before SignIn? Is this Objective-C specific usage?
It's the syntax for blocks.
That typedef declares SignIn
to mean a block which takes two NSString*
arguments and returns void
(i.e. nothing).
It is a block.
For a guide to understanding blocks, see this tutorial
Unless, you already know what a block is, and you just didn't know what the caret was for.