[PATCH] D23221: [NFC][ObjC Availability] Split up DiagnoseAvailabilityOfDecl, remove redundant enumeration

Erik Pilkington via cfe-commits cfe-commits at lists.llvm.org
Fri Aug 5 13:23:07 PDT 2016


erik.pilkington created this revision.
erik.pilkington added a reviewer: manmanren.
erik.pilkington added a subscriber: cfe-commits.

This patch removes the enum `Sema::AvailabilityDiagnostic`, which is redundant with `clang::AvailabilityResult`, and pulls out a function, `ShouldDiagnoseAvailabiltyOfDecl` from `DiagnoseAvailabiltyOfDecl`. This is so we can call `ShouldDiagnoseAvailabilityOfDecl` when emitting `-Wunguarded-availabilty`, which is done after Sema of a function.

This patch was originally part of https://reviews.llvm.org/D23003, but it was suggested that I separate it out.

https://reviews.llvm.org/D23221

Files:
  include/clang/Sema/DelayedDiagnostic.h
  include/clang/Sema/Sema.h
  lib/Sema/DelayedDiagnostic.cpp
  lib/Sema/SemaDeclAttr.cpp
  lib/Sema/SemaExpr.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D23221.66996.patch
Type: text/x-patch
Size: 14802 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160805/8c68c2e4/attachment-0001.bin>


More information about the cfe-commits mailing list