forked from OSchip/llvm-project
[ORC] Narrow a cast: the block guarded by the condition only handles
GlobalVariables, not all GlobalValues. llvm-svn: 343358
This commit is contained in:
parent
c06db02748
commit
b62f73420b
|
@ -36,7 +36,7 @@ static void extractAliases(MaterializationResponsibility &R, Module &M,
|
|||
A->replaceAllUsesWith(F);
|
||||
A->eraseFromParent();
|
||||
F->setName(AliasName);
|
||||
} else if (isa<GlobalValue>(Aliasee)) {
|
||||
} else if (isa<GlobalVariable>(Aliasee)) {
|
||||
auto *G = cloneGlobalVariableDecl(M, *cast<GlobalVariable>(Aliasee));
|
||||
A->replaceAllUsesWith(G);
|
||||
A->eraseFromParent();
|
||||
|
|
Loading…
Reference in New Issue