[PATCH] Add a truncation warning for values under a bitwise or

Sam Panzer espanz at gmail.com
Tue Feb 26 15:31:37 PST 2013


  Making this diagnostic work for bitwise and, without adding any extra diagnostics, was trickier than expected.

  I also tried rephrasing the warning to underline which of the operands will probably misbehave, though it probably still needs work.

http://llvm-reviews.chandlerc.com/D405

CHANGE SINCE LAST DIFF
  http://llvm-reviews.chandlerc.com/D405?vs=1070&id=1121#toc

Files:
  include/clang/Basic/DiagnosticSemaKinds.td
  lib/Sema/SemaChecking.cpp
  test/Sema/constant-conversion.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D405.7.patch
Type: text/x-patch
Size: 13669 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130226/4c13de59/attachment.bin>


More information about the cfe-commits mailing list