Created
March 12, 2013 02:59
-
-
Save lawrencelomax/5139946 to your computer and use it in GitHub Desktop.
Recursive Block macro http://blog.hyperjeff.net/code?id=335
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define recursiveBlock(type_out__, name__, type_in__, block__) \ | |
typedef type_out__ (^type_in_out__##name__)type_in__;\ | |
__weak __block type_in_out__##name__ name__;\ | |
type_in_out__##name__ temp__##name__;\ | |
name__ = temp__##name__ = ^type_out__(type_in__) block__ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment