[PATCH] D57064: [Sema] Improve a -Warray-bounds diagnostic

Erik Pilkington via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 22 12:46:08 PST 2019


erik.pilkington created this revision.
erik.pilkington added reviewers: aaron.ballman, rsmith.
Herald added subscribers: dexonsmith, jkorous.

Fix a bug where we would compare array sizes with incompatible element types, and look through explicit casts.

rdar://44800168

Thanks for taking a look!


Repository:
  rC Clang

https://reviews.llvm.org/D57064

Files:
  clang/include/clang/AST/ASTContext.h
  clang/include/clang/Basic/DiagnosticSemaKinds.td
  clang/lib/Sema/SemaExpr.cpp
  clang/test/Sema/static-array.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57064.182960.patch
Type: text/x-patch
Size: 4419 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190122/634e0e8e/attachment-0001.bin>


More information about the cfe-commits mailing list