diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2011-02-24 20:31:44 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2011-02-24 20:31:44 +0000 |
commit | bab380c2c8b3527e0448eb6252bc75f0de37fbca (patch) | |
tree | b28fcb2981800fa57e32fc74183fb6c91286ce77 /lib/CodeGen/CGDecl.cpp | |
parent | 094b64336495496ca29bc1e4774f5e2ceed79096 (diff) |
Use private linkage to avoid symbol conflicts in corner cases like the one
in PR9301.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126422 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r-- | lib/CodeGen/CGDecl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp index 844b1e37b0..f4db01d257 100644 --- a/lib/CodeGen/CGDecl.cpp +++ b/lib/CodeGen/CGDecl.cpp @@ -642,7 +642,7 @@ CodeGenFunction::EmitAutoVarAlloca(const VarDecl &D) { // candidate nor a __block variable, emit it as a global instead. if (CGM.getCodeGenOpts().MergeAllConstants && Ty.isConstQualified() && !NRVO && !isByRef) { - EmitStaticVarDecl(D, llvm::GlobalValue::InternalLinkage); + EmitStaticVarDecl(D, llvm::GlobalValue::PrivateLinkage); emission.Address = 0; // signal this condition to later callbacks assert(emission.wasEmittedAsGlobal()); |