summaryrefslogtreecommitdiff
path: root/lib/Sema/ScopeInfo.cpp
diff options
context:
space:
mode:
authorErik Pilkington <erik.pilkington@gmail.com>2016-08-16 17:44:11 +0000
committerErik Pilkington <erik.pilkington@gmail.com>2016-08-16 17:44:11 +0000
commit1d09f0125a41d3a5583b29b1bb0f55a2ccc604b3 (patch)
tree83a9a924b2d55debe4a430c0e97534ad4d833e22 /lib/Sema/ScopeInfo.cpp
parentda17e40e629d759650155858c58591e976c0b15d (diff)
downloadclang-1d09f0125a41d3a5583b29b1bb0f55a2ccc604b3.tar.gz
[ObjC] Warn on unguarded use of partial declaration
This commit adds a traversal of the AST after Sema of a function that diagnoses unguarded references to declarations that are partially available (based on availability attributes). This traversal is only done when we would otherwise emit -Wpartial-availability. This commit is part of a feature I proposed here: http://lists.llvm.org/pipermail/cfe-dev/2016-July/049851.html Differential revision: https://reviews.llvm.org/D23003 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@278826 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/ScopeInfo.cpp')
-rw-r--r--lib/Sema/ScopeInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Sema/ScopeInfo.cpp b/lib/Sema/ScopeInfo.cpp
index 4b2e13e20d..76240bcbfc 100644
--- a/lib/Sema/ScopeInfo.cpp
+++ b/lib/Sema/ScopeInfo.cpp
@@ -29,6 +29,7 @@ void FunctionScopeInfo::Clear() {
HasIndirectGoto = false;
HasDroppedStmt = false;
HasOMPDeclareReductionCombiner = false;
+ HasPotentialAvailabilityViolations = false;
ObjCShouldCallSuper = false;
ObjCIsDesignatedInit = false;
ObjCWarnForNoDesignatedInitChain = false;