summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprScalar.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2010-09-03 02:07:00 +0000
committerDaniel Dunbar <daniel@zuster.org>2010-09-03 02:07:00 +0000
commit2f8df98c92e1b98aeb0b3a76a13f60ce8c438f0d (patch)
tree7b3250bd236129fac4ce53fe3134214d2baf16d1 /clang/lib/CodeGen/CGExprScalar.cpp
parenta85ec1048391d1e242ceab8ed8ca4938183b3da6 (diff)
downloadbcm5719-llvm-2f8df98c92e1b98aeb0b3a76a13f60ce8c438f0d.tar.gz
bcm5719-llvm-2f8df98c92e1b98aeb0b3a76a13f60ce8c438f0d.zip
IRgen: Fix silly thinko in r112021, which was generating code for the same expr
twice. This showed up as an assert on the odd test case because we generated the decl map entry twice. llvm-svn: 112943
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 fd77a67606b..4e16f66ba42 100644
--- a/clang/lib/CodeGen/CGExprScalar.cpp
+++ b/clang/lib/CodeGen/CGExprScalar.cpp
@@ -1033,7 +1033,7 @@ Value *ScalarExprEmitter::EmitCastExpr(CastExpr *CE) {
// Handle conversion to bool correctly.
if (DestTy->isBooleanType())
- return EmitScalarConversion(Visit(E), E->getType(), DestTy);
+ return EmitScalarConversion(Src, E->getType(), DestTy);
return Builder.CreatePtrToInt(Src, ConvertType(DestTy));
}
OpenPOWER on IntegriCloud