[cfe-commits] r113397 - in /cfe/trunk: include/clang/AST/Type.h lib/AST/Type.cpp lib/Sema/SemaType.cpp test/SemaObjC/legacy-objc-types.m test/SemaObjCXX/legacy-objc-types.mm

Argyrios Kyrtzidis akyrtzi at gmail.com
Thu Sep 9 01:45:59 PDT 2010


On Sep 8, 2010, at 10:59 PM, John McCall wrote:

>> 
>> I agree on this point. I can tighten up the type checking.
>> In any case, point of this patch was to fix the crash in a limited case and not treat 'struct objc_object' as a replacement for 'id' everywhere.
>> So, these are alternatives.
>> 
>> 1. Do nothing and let the test case crash ( I think it was a manufactured test ).
>> 2. Accept the alternative 'struct ...' as builtin type everywhere.
>> 3. Issue error if it is used anywhere.
>> 4.???
> 
> Personally I like #3 because ObjC code using 'struct objc_object' is very likely to either not compile or have really unfortunate behavioral changes — I think Argyrios recently hunted down something in the latter category — but that's the sort of problem we can only suss out with SWBs.  For the immediate problem, changing FunctionArgTypesAreEqual should be enough.

FWIW, I came upon the crash while testing out how 'struct objc_object' is handled in clang. So it wasn't in 'real' code but letting in known crashes is really bad IMO.

-Argiris

> 
> John.
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits





More information about the cfe-commits mailing list