John - 2015-02-23

In fact, this issue doesn't have anything to do with the macro definition, you can reproduce this issue more simply like this:

MACRO(if (a == 1) b = 2;)
MACRO(c = 3;)

Which is turned into:

MACRO(if (a == 1) b = 2;)
{
    MACRO(c = 3;
})

(ie ")" outside of "}").

Here, the "if" is prompting the creation of "{ ... }", but the trailing ")" for the second macro ends up outside of that.