[cfe-dev] Statement scoping issue

Chris Lattner clattner at apple.com
Sun Aug 26 16:08:43 PDT 2007


On Aug 26, 2007, at 4:03 PM, Neil Booth wrote:

> Neil Booth wrote:-
>
>> C99 scoping seems to work apart from this, whose return b is invalid
>> as there is no "b" in scope:
>>
>> int f (int z)
>> {
>>    if (z > sizeof (enum {a, b}))
>>       return a;
>>    return b;
>> }
>
> Fixed below.

Very nice Neil, thanks!

-Chris





More information about the cfe-dev mailing list