[PATCH] D41512: [Sema] -Wtautological-constant-compare is too good. Cripple it.

Roman Lebedev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Dec 25 00:45:46 PST 2017


lebedev.ri updated this revision to Diff 128128.
lebedev.ri added a comment.

Move `TautologicalUnsignedZeroCompare` and `TautologicalUnsignedEnumZeroCompare` into `TautologicalRangeCompare` too, and enable them only in `-Wextra`.
Please advise re flag name for `warn_tautological_constant_compare`.


Repository:
  rC Clang

https://reviews.llvm.org/D41512

Files:
  include/clang/Basic/DiagnosticGroups.td
  include/clang/Basic/DiagnosticSemaKinds.td
  test/Sema/compare.c
  test/Sema/tautological-constant-compare.c
  test/Sema/tautological-constant-enum-compare.c
  test/Sema/tautological-unsigned-enum-zero-compare.c
  test/Sema/tautological-unsigned-enum-zero-compare.cpp
  test/Sema/tautological-unsigned-zero-compare.c
  test/SemaCXX/compare.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41512.128128.patch
Type: text/x-patch
Size: 9052 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171225/b84ebe1c/attachment-0001.bin>


More information about the cfe-commits mailing list