Use mayBeOverridden here, in anticipation of the

day when more linkage types will be handled.

llvm-svn: 61944
This commit is contained in:
Duncan Sands 2009-01-08 20:55:49 +00:00
parent 0667123ba1
commit 715b2897d8
1 changed files with 2 additions and 2 deletions

View File

@ -252,7 +252,7 @@ const GlobalValue *GlobalAlias::resolveAliasedGlobal(bool stopOnWeak) const {
SmallPtrSet<const GlobalValue*, 3> Visited;
// Check if we need to stop early.
if (stopOnWeak && hasWeakLinkage())
if (stopOnWeak && mayBeOverridden())
return this;
const GlobalValue *GV = getAliasedGlobal();
@ -260,7 +260,7 @@ const GlobalValue *GlobalAlias::resolveAliasedGlobal(bool stopOnWeak) const {
// Iterate over aliasing chain, stopping on weak alias if necessary.
while (const GlobalAlias *GA = dyn_cast<GlobalAlias>(GV)) {
if (stopOnWeak && GA->hasWeakLinkage())
if (stopOnWeak && GA->mayBeOverridden())
break;
GV = GA->getAliasedGlobal();