aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGExprScalar.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-11-24 05:12:34 +0000
committerJohn McCall <rjmccall@apple.com>2010-11-24 05:12:34 +0000
commit7eb0a9eb0cde8444b97f9c5b713d9be7a6f1e607 (patch)
treee828a6fb6060ac7711b5209210bfd31c15de71af /lib/CodeGen/CGExprScalar.cpp
parent834f9de3d3d76986d09f41725a70ba45a3e2aecd (diff)
Switch a lot of call-sites over to using the new value-kind calculations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120084 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprScalar.cpp')
-rw-r--r--lib/CodeGen/CGExprScalar.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/CGExprScalar.cpp b/lib/CodeGen/CGExprScalar.cpp
index a5f9890c12..e5ea26c24b 100644
--- a/lib/CodeGen/CGExprScalar.cpp
+++ b/lib/CodeGen/CGExprScalar.cpp
@@ -1474,7 +1474,7 @@ Value *ScalarExprEmitter::VisitUnaryReal(const UnaryOperator *E) {
// If it's an l-value, load through the appropriate subobject l-value.
// Note that we have to ask E because Op might be an l-value that
// this won't work for, e.g. an Obj-C property.
- if (E->isLvalue(CGF.getContext()) == Expr::LV_Valid)
+ if (E->isGLValue())
return CGF.EmitLoadOfLValue(CGF.EmitLValue(E), E->getType())
.getScalarVal();
@@ -1491,7 +1491,7 @@ Value *ScalarExprEmitter::VisitUnaryImag(const UnaryOperator *E) {
// If it's an l-value, load through the appropriate subobject l-value.
// Note that we have to ask E because Op might be an l-value that
// this won't work for, e.g. an Obj-C property.
- if (Op->isLvalue(CGF.getContext()) == Expr::LV_Valid)
+ if (Op->isGLValue())
return CGF.EmitLoadOfLValue(CGF.EmitLValue(E), E->getType())
.getScalarVal();
@@ -2548,7 +2548,7 @@ LValue CodeGenFunction::EmitObjCIsaExpr(const ObjCIsaExpr *E) {
const llvm::Type *ClassPtrTy = ConvertType(E->getType());
Expr *BaseExpr = E->getBase();
- if (BaseExpr->isLvalue(getContext()) != Expr::LV_Valid) {
+ if (BaseExpr->isRValue()) {
V = CreateTempAlloca(ClassPtrTy, "resval");
llvm::Value *Src = EmitScalarExpr(BaseExpr);
Builder.CreateStore(Src, V);