aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGDeclCXX.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2010-02-03 16:38:03 +0000
committerAnders Carlsson <andersca@mac.com>2010-02-03 16:38:03 +0000
commita64a869312066ff6119d1d7ae03f88ce499e3f82 (patch)
tree5ff2531884f675da36cc3d8f41779a9d36cee6ba /lib/CodeGen/CGDeclCXX.cpp
parentef6e0f3218b64d8ea3b8b57ee657fec8da228a43 (diff)
Revert the new reference binding code; I came up with a way simpler solution for the reference binding bug that is preventing self-hosting.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95223 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDeclCXX.cpp')
-rw-r--r--lib/CodeGen/CGDeclCXX.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/CGDeclCXX.cpp b/lib/CodeGen/CGDeclCXX.cpp
index 3f1a7225fb..3d5a4e8051 100644
--- a/lib/CodeGen/CGDeclCXX.cpp
+++ b/lib/CodeGen/CGDeclCXX.cpp
@@ -81,7 +81,7 @@ void CodeGenFunction::EmitCXXGlobalVarDeclInit(const VarDecl &D,
return;
}
if (Init->isLvalue(getContext()) == Expr::LV_Valid) {
- RValue RV = EmitReferenceBindingToExpr(Init, T, /*IsInitializer=*/true);
+ RValue RV = EmitReferenceBindingToExpr(Init, /*IsInitializer=*/true);
EmitStoreOfScalar(RV.getScalarVal(), DeclPtr, false, T);
return;
}
@@ -225,7 +225,7 @@ CodeGenFunction::EmitStaticCXXBlockVarDeclInit(const VarDecl &D,
QualType T = D.getType();
// We don't want to pass true for IsInitializer here, because a static
// reference to a temporary does not extend its lifetime.
- RValue RV = EmitReferenceBindingToExpr(D.getInit(), T,
+ RValue RV = EmitReferenceBindingToExpr(D.getInit(),
/*IsInitializer=*/false);
EmitStoreOfScalar(RV.getScalarVal(), GV, /*Volatile=*/false, T);