simplify this logic now that GlobalAlias::isDeclaration is fixed.

llvm-svn: 135183
This commit is contained in:
Chris Lattner 2011-07-14 20:23:05 +00:00
parent 81210d232d
commit 0c134b52b9
1 changed files with 2 additions and 4 deletions

View File

@ -437,10 +437,8 @@ bool ModuleLinker::getLinkageResult(GlobalValue *Dest, const GlobalValue *Src,
assert(!Src->hasLocalLinkage() &&
"If Src has internal linkage, Dest shouldn't be set!");
// FIXME: GlobalAlias::isDeclaration is broken, should always be
// false.
bool SrcIsDeclaration = Src->isDeclaration() && !isa<GlobalAlias>(Src);
bool DestIsDeclaration = Dest->isDeclaration() && !isa<GlobalAlias>(Dest);
bool SrcIsDeclaration = Src->isDeclaration();
bool DestIsDeclaration = Dest->isDeclaration();
if (SrcIsDeclaration) {
// If Src is external or if both Src & Dest are external.. Just link the