summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-02-13 22:58:39 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-02-13 22:58:39 +0000
commitf9f039865fbc0430750210141c9210d7eaf456b2 (patch)
tree7f6e88cea5b662b2aceef197c89493bddc64d344 /clang/lib/CodeGen/CGDecl.cpp
parent165b527507b27b939737a61114238a9abe295017 (diff)
downloadbcm5719-llvm-f9f039865fbc0430750210141c9210d7eaf456b2.tar.gz
bcm5719-llvm-f9f039865fbc0430750210141c9210d7eaf456b2.zip
Set constant bit on static block vars as well. Patch by Anders Johnson!q
llvm-svn: 64502
Diffstat (limited to 'clang/lib/CodeGen/CGDecl.cpp')
-rw-r--r--clang/lib/CodeGen/CGDecl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGDecl.cpp b/clang/lib/CodeGen/CGDecl.cpp
index ddc68d68c5e..bb2705ff60a 100644
--- a/clang/lib/CodeGen/CGDecl.cpp
+++ b/clang/lib/CodeGen/CGDecl.cpp
@@ -109,7 +109,7 @@ CodeGenFunction::GenerateStaticBlockVarDecl(const VarDecl &D,
assert(0 && "Unknown context for block var decl");
llvm::GlobalValue *GV =
- new llvm::GlobalVariable(Init->getType(), false,
+ new llvm::GlobalVariable(Init->getType(), Ty.isConstant(getContext()),
Linkage,
Init, ContextName + Separator +D.getNameAsString(),
&CGM.getModule(), 0, Ty.getAddressSpace());
OpenPOWER on IntegriCloud