[cfe-commits] r64994 - in /cfe/trunk/lib: AST/ExprConstant.cpp CodeGen/CGBlocks.cpp CodeGen/CGExprConstant.cpp CodeGen/CGExprScalar.cpp CodeGen/CodeGenModule.h

Fariborz Jahanian fjahanian at apple.com
Thu Feb 19 09:22:48 PST 2009


On Feb 19, 2009, at 9:13 AM, Chris Lattner wrote:

> On Feb 19, 2009, at 9:08 AM, Fariborz Jahanian wrote:
>>> Hmm, I might be confused about something, but take something like  
>>> the
>>> following (I haven't checked if this particular example compiles,  
>>> but
>>> this sort of thing is legal):
>>> int a(int x) {
>>> static int (^y)(void) = ^{x;};
>>> return y();
>>> }
>>
>> Above is illegal, as you are importing a local variable in a static
>> block. gcc complains
>> (which of course can be improved ):
>
> Right, but Mike's change breaks this in clang.  Clang now  
> incorrectly accepts this.

which is bad.

- Fariborz

>
>
> -Chris




More information about the cfe-commits mailing list