diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2012-03-02 23:27:11 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2012-03-02 23:27:11 +0000 |
commit | bc638767f8456cec12271962e3a947528e7348e3 (patch) | |
tree | d93aa2d90d3496231500b31b68d49fe09742a066 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | 44f6bddb17c795acfa7fb704f5ed48fc6d39afb1 (diff) | |
download | bcm5719-llvm-bc638767f8456cec12271962e3a947528e7348e3.tar.gz bcm5719-llvm-bc638767f8456cec12271962e3a947528e7348e3.zip |
Reinstate r151879, r151880, reverted in r151922, along with a bugfix for
scalar emission of DeclRefExprs to const bools: emit scalar bools as i1,
not as i8.
In addition to the extra unit testing, this has successfully bootstrapped.
llvm-svn: 151955
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index a3a71b7e523..922a5df344f 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -1472,7 +1472,8 @@ CodeGenModule::MaybeEmitGlobalStdInitializerListInitializer(const VarDecl *D, } // Emit the constant for the initializer_list. - llvm::Constant *llvmInit = EmitConstantValue(initListValue, D->getType()); + llvm::Constant *llvmInit = + EmitConstantValueForMemory(initListValue, D->getType()); assert(llvmInit && "failed to initialize as constant"); return llvmInit; } |