[cfe-commits] r172102 - in /cfe/trunk: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaStmt.cpp test/Sema/switch-1.c

jahanian fjahanian at apple.com
Thu Jan 10 12:48:33 PST 2013


On Jan 10, 2013, at 12:44 PM, Dmitri Gribenko <gribozavr at gmail.com> wrote:

> On Thu, Jan 10, 2013 at 10:26 PM, Fariborz Jahanian <fjahanian at apple.com> wrote:
>> Author: fjahanian
>> Date: Thu Jan 10 14:26:42 2013
>> New Revision: 172102
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=172102&view=rev
>> Log:
>> Provide a better warning when case value overflows.
>> // rdar://11577384
>> 
>> Modified:
>>    cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
>>    cfe/trunk/lib/Sema/SemaStmt.cpp
>>    cfe/trunk/test/Sema/switch-1.c
>> 
>> Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
>> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td?rev=172102&r1=172101&r2=172102&view=diff
>> ==============================================================================
>> --- cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td (original)
>> +++ cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Thu Jan 10 14:26:42 2013
>> @@ -5712,6 +5712,9 @@
>> def warn_case_value_overflow : Warning<
>>   "overflow converting case value to switch condition type (%0 to %1)">,
>>   InGroup<Switch>;
>> +def warn_case_constant_overflow : Warning<
>> +  "overflow in case constant expression results in new value (%0)">,
>> +  InGroup<DiagGroup<"switch">>;
> 
> Hi Fariborz,
> 
> Please use InGroup<Switch> here.

In r172103.
- Thanks, Fariborz

> 
> Dmitri
> 




More information about the cfe-commits mailing list