[cfe-commits] r119583 - in /cfe/trunk: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td include/clang/Basic/LangOptions.h include/clang/Driver/CC1Options.td include/clang/Driver/Options.td include/clang/Sema/Sema.h lib/Driver/Tools.cpp lib/Frontend/CompilerInvocation.cpp lib/Sema/SemaDecl.cpp test/SemaCXX/warn-argument-larger-than.cpp

Argyrios Kyrtzidis kyrtzidis at apple.com
Thu Nov 18 10:53:55 PST 2010


On Nov 17, 2010, at 9:15 PM, Chris Lattner wrote:

> 
> On Nov 17, 2010, at 7:54 PM, Argyrios Kyrtzidis wrote:
> 
>>>> 
>>>> ASTContext::getTypeInfo will calculate a ASTRecordLayout if one is not available.
>>>> It's debatable whether we will avoid it but better be on the safe side ?
>>> 
>>> When does this warning trigger?  IMO, it would make sense to only do it on function definitions, not prototypes (because if you just have a proto, you probably don't have the option to change it, and that way you don't get the warning in every translation unit).
>> 
>> Yes, only on function definitions.
>> 
>>> 
>>> If it just triggers on definitions, the layout will have to be computed at codegen time, so it shouldn't add any cost to -O0 compiles.
>> 
>> That's true but I was thinking about non-codegen situations like indexing ?
> 
> *shrug* I still think it's worth it to be simple.

Ok, removed at r119719.

-Argiris

> 
> -Chris
> _______________________________________________
> 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