[PATCH] D26109: Warn when 'assume_nonnull' infers nullability within an array.

Jordan Rose via cfe-commits cfe-commits at lists.llvm.org
Fri Oct 28 17:45:38 PDT 2016


jordan_rose created this revision.
jordan_rose added a reviewer: doug.gregor.
jordan_rose added a subscriber: cfe-commits.
jordan_rose set the repository for this revision to rL LLVM.
jordan_rose added a dependency: D25850: Accept nullability annotations (_Nullable) on array parameters.

...or within a reference. Both of these add an extra level of indirection that make us less certain that the pointer really was supposed to be non-nullable. However, changing the default behavior would be a breaking change, so we'll just make it a warning instead.

Depends on https://reviews.llvm.org/D25850. Part of rdar://problem/25846421.


Repository:
  rL LLVM

https://reviews.llvm.org/D26109

Files:
  include/clang/Basic/DiagnosticGroups.td
  include/clang/Basic/DiagnosticSemaKinds.td
  lib/Sema/SemaType.cpp
  test/FixIt/nullability.mm
  test/SemaObjCXX/nullability-consistency-arrays.mm

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26109.76284.patch
Type: text/x-patch
Size: 12197 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20161029/a7a44aba/attachment.bin>


More information about the cfe-commits mailing list