forked from OSchip/llvm-project
Another work around for the 'symbols with different types can have the same
name' issue. llvm-svn: 26149
This commit is contained in:
parent
a438ef0ee7
commit
eea0f0198e
|
@ -161,6 +161,10 @@ void Mangler::InsertName(GlobalValue *GV,
|
|||
if (GV->hasExternalLinkage() && !ExistingValue->hasExternalLinkage()) {
|
||||
MangledGlobals.insert(ExistingValue);
|
||||
ExistingValue = GV;
|
||||
} else if (GV->hasExternalLinkage() && ExistingValue->hasExternalLinkage()&&
|
||||
GV->isExternal() && ExistingValue->isExternal()) {
|
||||
// If the two globals both have external inkage, and are both external,
|
||||
// don't mangle either of them, we just have some silly type mismatch.
|
||||
} else {
|
||||
// Otherwise, mangle GV
|
||||
MangledGlobals.insert(GV);
|
||||
|
|
Loading…
Reference in New Issue