Update for llvm api change.

llvm-svn: 209077
This commit is contained in:
Rafael Espindola
2014-05-17 21:30:14 +00:00
parent f1bedd3747
commit 234405bd0f
5 changed files with 12 additions and 12 deletions

View File

@@ -2269,7 +2269,7 @@ void CodeGenModule::EmitAliasDefinition(GlobalDecl GD) {
llvm::PointerType::getUnqual(DeclTy), 0);
// Create the new alias itself, but don't set a name yet.
auto *GA = new llvm::GlobalAlias(
auto *GA = llvm::GlobalAlias::create(
cast<llvm::PointerType>(Aliasee->getType())->getElementType(), 0,
llvm::Function::ExternalLinkage, "",
&getGlobalObjectInExpr(Diags, AA, Aliasee));
@@ -3197,8 +3197,8 @@ void CodeGenModule::EmitStaticExternCAliases() {
IdentifierInfo *Name = I->first;
llvm::GlobalValue *Val = I->second;
if (Val && !getModule().getNamedValue(Name->getName()))
addUsedGlobal(new llvm::GlobalAlias(Name->getName(),
cast<llvm::GlobalObject>(Val)));
addUsedGlobal(llvm::GlobalAlias::create(Name->getName(),
cast<llvm::GlobalObject>(Val)));
}
}