summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprConstant.cpp
diff options
context:
space:
mode:
authorSebastian Redl <sebastian.redl@getdesigned.at>2012-02-25 20:51:20 +0000
committerSebastian Redl <sebastian.redl@getdesigned.at>2012-02-25 20:51:20 +0000
commit4a7eab25455e68ce928c5fcd7947998118e5cb5c (patch)
treeca4e084cf67dbad4e1de245e56b849f800ac2b31 /clang/lib/CodeGen/CGExprConstant.cpp
parentf2e0a3077cf34a537300f34b0457c91f35e40785 (diff)
downloadbcm5719-llvm-4a7eab25455e68ce928c5fcd7947998118e5cb5c.tar.gz
bcm5719-llvm-4a7eab25455e68ce928c5fcd7947998118e5cb5c.zip
CodeGen support for global variables of type std::initializer_list<X>.
This emits a backing array with internal linkage and fills it with data, then has the initializer_list point at the array. Dynamic initialization and global destructors are correctly supported. What doesn't work is nested initializer_lists. I have no idea how to get them to work, either. However, these should be very rare, and so I'll just call it a known bug and declare generalized initializers DONE! llvm-svn: 151457
Diffstat (limited to 'clang/lib/CodeGen/CGExprConstant.cpp')
-rw-r--r--clang/lib/CodeGen/CGExprConstant.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExprConstant.cpp b/clang/lib/CodeGen/CGExprConstant.cpp
index a074466ec53..2803640bdaf 100644
--- a/clang/lib/CodeGen/CGExprConstant.cpp
+++ b/clang/lib/CodeGen/CGExprConstant.cpp
@@ -369,7 +369,7 @@ void ConstStructBuilder::ConvertStructToPacked() {
bool ConstStructBuilder::Build(InitListExpr *ILE) {
if (ILE->initializesStdInitializerList()) {
- CGM.ErrorUnsupported(ILE, "global std::initializer_list");
+ //CGM.ErrorUnsupported(ILE, "global std::initializer_list");
return false;
}
OpenPOWER on IntegriCloud