aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2011-08-24 00:33:55 +0000
committerEric Christopher <echristo@apple.com>2011-08-24 00:33:55 +0000
commit736a9c211c065784f7a7889ade55aa569a89520e (patch)
tree6d848699d1fd6d5931fb47d5744e1b959c55756d /lib/CodeGen/CGDecl.cpp
parent6cf0ed062fb7ff3def3b627bab8ca275a549579e (diff)
Make constant aggregate constant initializers private linkage.
After talking with John making this the case for all of these is the right way to go. Fixes rdar://9804564 and PR10414 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138418 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r--lib/CodeGen/CGDecl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp
index 6d1e9b03ab..0f6ceedb25 100644
--- a/lib/CodeGen/CGDecl.cpp
+++ b/lib/CodeGen/CGDecl.cpp
@@ -982,7 +982,7 @@ void CodeGenFunction::EmitAutoVarInit(const AutoVarEmission &emission) {
std::string Name = GetStaticDeclName(*this, D, ".");
llvm::GlobalVariable *GV =
new llvm::GlobalVariable(CGM.getModule(), constant->getType(), true,
- llvm::GlobalValue::InternalLinkage,
+ llvm::GlobalValue::PrivateLinkage,
constant, Name, 0, false, 0);
GV->setAlignment(alignment.getQuantity());
GV->setUnnamedAddr(true);