aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaExprCXX.cpp
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2012-01-16 21:00:51 +0000
committerEli Friedman <eli.friedman@gmail.com>2012-01-16 21:00:51 +0000
commitcf7c14c3451658311aeaed84c6395082fa91e60d (patch)
tree8da3d322e75918e347e3b4f0b63d07e43d0801c5 /lib/Sema/SemaExprCXX.cpp
parent100d04165571d42437c8e74482534e69495540ec (diff)
Add some calls to MarkDeclarationReferenced, towards a point where every declaration which is used is marked as used.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148253 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExprCXX.cpp')
-rw-r--r--lib/Sema/SemaExprCXX.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index ee25591529..6476f4a512 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -2043,6 +2043,9 @@ ExprResult Sema::CheckConditionVariable(VarDecl *ConditionVar,
ConditionVar->getLocation(),
ConditionVar->getType().getNonReferenceType(),
VK_LValue));
+
+ MarkDeclarationReferenced(ConditionVar->getLocation(), ConditionVar);
+
if (ConvertToBoolean) {
Condition = CheckBooleanCondition(Condition.take(), StmtLoc);
if (Condition.isInvalid())