summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprScalar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/CGExprScalar.cpp')
-rw-r--r--clang/lib/CodeGen/CGExprScalar.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExprScalar.cpp b/clang/lib/CodeGen/CGExprScalar.cpp
index 8ed36aac5f1..9da493448aa 100644
--- a/clang/lib/CodeGen/CGExprScalar.cpp
+++ b/clang/lib/CodeGen/CGExprScalar.cpp
@@ -217,7 +217,7 @@ public:
VarDecl *VD = dyn_cast<VarDecl>(E->getDecl());
if (!VD && !isa<EnumConstantDecl>(E->getDecl()))
return EmitLoadOfLValue(E);
- if (VD && !VD->isUsableInConstantExpressions())
+ if (VD && !VD->isUsableInConstantExpressions(CGF.getContext()))
return EmitLoadOfLValue(E);
// This is an enumerator or a variable which is usable in constant
OpenPOWER on IntegriCloud