Revert "[opaque pointer type] update for LLVM API change"

This was the wrong direction to take anyway (because ultimately the
GlobalValue needed the pointee type again and /it/ used
PointerType::getElementType eventually anyway)... let's go a different way.

This reverts commit r236161.

llvm-svn: 247586
This commit is contained in:
David Blaikie
2015-09-14 18:02:04 +00:00
parent 16a2f3e302
commit aff29d3031
5 changed files with 11 additions and 10 deletions

View File

@@ -2772,7 +2772,7 @@ void CodeGenModule::EmitAliasDefinition(GlobalDecl GD) {
// Create the new alias itself, but don't set a name yet.
auto *GA = llvm::GlobalAlias::create(
cast<llvm::PointerType>(Aliasee->getType()),
cast<llvm::PointerType>(Aliasee->getType())->getElementType(), 0,
llvm::Function::ExternalLinkage, "", Aliasee, &getModule());
if (Entry) {