summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-07-15 18:12:28 +0000
committerDouglas Gregor <dgregor@apple.com>2010-07-15 18:12:28 +0000
commit6744cbda032f86977fed3f10931c0447867032ee (patch)
treec27828560bf99b47eaa3bef8c4edcda05dffbd3a /clang/lib/CodeGen
parentdf5d38478d9497b23c4069f95bba650e6815431c (diff)
downloadbcm5719-llvm-6744cbda032f86977fed3f10931c0447867032ee.tar.gz
bcm5719-llvm-6744cbda032f86977fed3f10931c0447867032ee.zip
Spell isPRValue() properly.
llvm-svn: 108433
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r--clang/lib/CodeGen/CGExpr.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGExpr.cpp b/clang/lib/CodeGen/CGExpr.cpp
index 94fb086b4c2..db4d23187df 100644
--- a/clang/lib/CodeGen/CGExpr.cpp
+++ b/clang/lib/CodeGen/CGExpr.cpp
@@ -1753,8 +1753,7 @@ LValue CodeGenFunction::EmitCastLValue(const CastExpr *E) {
return EmitUnsupportedLValue(E, "unexpected cast lvalue");
case CastExpr::CK_NoOp:
- if (E->getSubExpr()->getType()->isRecordType() ||
- E->getSubExpr()->isLvalue(getContext()) == Expr::LV_Valid) {
+ if (!E->getSubExpr()->Classify(getContext()).isPRValue()) {
LValue LV = EmitLValue(E->getSubExpr());
if (LV.isPropertyRef()) {
QualType QT = E->getSubExpr()->getType();
OpenPOWER on IntegriCloud