Add a destination type argument to EmitConstantExpr. This will be used for when the destination has a reference type. (No functionality change yet)
llvm-svn: 68593
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 508d7ce..2c1ab1f 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -693,7 +693,7 @@
}
Init = llvm::Constant::getNullValue(InitTy);
} else {
- Init = EmitConstantExpr(D->getInit());
+ Init = EmitConstantExpr(D->getInit(), D->getType());
if (!Init) {
ErrorUnsupported(D, "static initializer");
QualType T = D->getInit()->getType();