[cfe-users] How do I output Clang's source code transition of Blocks?

Richard Catlin richard.m.catlin at gmail.com
Tue May 13 15:42:06 PDT 2014

For example, the Block Implementation Specification says

^ { printf("hello world\n"); }

is translated to

struct __block_literal_1 {
void *isa;
int flags;
int reserved;
void (*invoke)(struct __block_literal_1 *);
struct __block_descriptor_1 *descriptor;
void __block_invoke_1(struct __block_literal_1 *_block) {
printf("hello world\n");
static struct __block_descriptor_1 {
unsigned long int reserved;
unsigned long int Block_size;
} __block_descriptor_1 = { 0, sizeof(struct __block_literal_1), __block_invoke_1 };

struct __block_literal_1 _block_literal = {
(1<<29), <uninitialized>,

Thanks for any help.
Richard Catlin

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-users/attachments/20140513/4770946a/attachment.html>

More information about the cfe-users mailing list